GithubHelp home page GithubHelp logo

gulp-premailer's People

Contributors

justin713 avatar pdufour avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

gulp-premailer's Issues

URL Encoding w/n Mustache Syntax

Any chance for slightly improved support when using Mustache syntax in templates? I am running into the following issue due to URL encoding within mustaches inside URLs or option to disable globally?

Input:

<a href="{{ url('password/reset/'.$token) }}">{{ url('password/reset/'.$token) }}</a>

Premailer Output:

<a href="%7B%7B%20url('password/reset/'.%24token)%20%7D%7D">{{ url('password/reset/'.$token) }}</a>

premailer dosent premail files with '_' prefix

I got a funny "im not sure if its a bug" but if i premail a file and its prefixed with the _ sign its like it dosent premail it. For instance i run a gulp premailer setup with a Jinja template engine so a structure for me looks like this:

dev folder:
_layout.html
email-name.html

When i render run the premailer it runs only only on "email-name.html" and not the _layout.html but if i remove the _ it dose.

Any suggestions why this could happen ?

Docs

Any chance of getting docs on this plugin?

Using premailer after gulp-file-include breaks the file including part

We have a gulp task like this using gulp-file-include:

gulp.task 'templates', ->
  gulp.src 'assets/templates/*.php'
    .pipe fileinclude({
      prefix: '@@',
      basepath: '@file'
    })
    .pipe premailer()
    .pipe gulp.dest templates_dest

When the pipe through premailer() is enabled, the generated output does not have the processed include file, instead the 'include' command remains in the template. When disabling the premailer pipe, the template output is as we expect, namely with the include command being replaced with the actual content of the file that we want to include.

How/why is this happening?

Template contains:

blabla html

@@include('includes/footer.blade.php')

blabla more html

Options for escaping url attributes

Is it possible to create an option for escaping url attributes?
Premailer supports escape_url_attributes:false. Is it possible to add this option in gulp-premailer?

Option for remove-scripts=false?

I was playing around with trying to pass --remove-scripts=false, and it looks like it's available via command line options in the Docs.

I went in and did some hacking (added "remove-scripts" to the needsValue array) and when I was able to get the args to append to the call out to premailer, the error was "needless argument"

Error:
/Library/Ruby/Gems/2.0.0/gems/premailer-1.8.4/lib/premailer/executor.rb:77:in `<top (required)>': needless argument: --remove-scripts=false (OptionParser::NeedlessArgument)

Any guidance here? Apologies if this is also like #6, where this is not available, but it's listed in the -- args linked above.

Error [gulp-premailer] spawn ENOENT

I am getting a 'Error [gulp-premailer] spawn ENOENT' when running it on a html file.

Error [gulp-premailer] spawn ENOENT
    at errnoException (child_process.js:1001:11)
    at Process.ChildProcess._handle.onexit (child_process.js:792:34)
Error stream.push() after EOF
    at readableAddChunk (/Users/daphnes/Sites/timing/email/node_modules/gulp-premailer/node_modules/through2/node_modules/readable-stream/lib/_stream_readable.js:168:15)
    at Transform.Readable.push (/Users/daphnes/Sites/timing/email/node_modules/gulp-premailer/node_modules/through2/node_modules/readable-stream/lib/_stream_readable.js:149:10)
    at Transform.push (/Users/daphnes/Sites/timing/email/node_modules/gulp-premailer/node_modules/through2/node_modules/readable-stream/lib/_stream_transform.js:145:32)
    at ChildProcess.<anonymous> (/Users/daphnes/Sites/timing/email/node_modules/gulp-premailer/index.js:115:9)
    at ChildProcess.emit (events.js:98:17)
    at maybeClose (child_process.js:756:16)
    at Socket.<anonymous> (child_process.js:969:11)
    at Socket.emit (events.js:95:17)
    at Pipe.close (net.js:465:12)
Error no writecb in Transform class
    at afterTransform (/Users/daphnes/Sites/timing/email/node_modules/gulp-premailer/node_modules/through2/node_modules/readable-stream/lib/_stream_transform.js:95:33)
    at TransformState.afterTransform (/Users/daphnes/Sites/timing/email/node_modules/gulp-premailer/node_modules/through2/node_modules/readable-stream/lib/_stream_transform.js:79:12)
    at ChildProcess.<anonymous> (/Users/daphnes/Sites/timing/email/node_modules/gulp-premailer/index.js:116:4)
    at ChildProcess.emit (events.js:98:17)
    at maybeClose (child_process.js:756:16)
    at Socket.<anonymous> (child_process.js:969:11)
    at Socket.emit (events.js:95:17)
    at Pipe.close (net.js:465:12)

Inline multiple font-size

I am using rem unit to my fonte size and i have px unit to fallback.
But premailer is striping them and letting only the first attribute inline.

h1 { font-size: 32px; font-size: 3.2rem; line-height: 40px; line-height: 4rem; margin-bottom: 32px; margin-bottom: 3.2rem; font-weight: 500; }

Thanks in advance

Error while installing

This is related to NPM right?

โ†’ npmi gulp-premailer
npm WARN package.json [email protected] No description
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] No README data
npm http GET https://registry.npmjs.org/gulp-premailer
npm http GET https://registry.npmjs.org/gulp-premailer
npm http GET https://registry.npmjs.org/gulp-premailer
npm ERR! Error: SELF_SIGNED_CERT_IN_CHAIN
npm ERR!     at SecurePair.<anonymous> (tls.js:1350:32)
npm ERR!     at SecurePair.EventEmitter.emit (events.js:92:17)
npm ERR!     at SecurePair.maybeInitFinished (tls.js:963:10)
npm ERR!     at CleartextStream.read [as _read] (tls.js:463:15)
npm ERR!     at CleartextStream.Readable.read (_stream_readable.js:320:10)
npm ERR!     at EncryptedStream.write [as _write] (tls.js:366:25)
npm ERR!     at doWrite (_stream_writable.js:219:10)
npm ERR!     at writeOrBuffer (_stream_writable.js:209:5)
npm ERR!     at EncryptedStream.Writable.write (_stream_writable.js:180:11)
npm ERR!     at write (_stream_readable.js:575:24)
npm ERR! If you need help, you may report this log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <[email protected]>

npm ERR! System Darwin 13.1.0
npm ERR! command "node" "/usr/local/bin/npm" "install" "--save-dev" "gulp-premailer"
npm ERR! cwd /Users/luismartins/Sites/idomlive/protected/views/mail/modelos_base
npm ERR! node -v v0.10.16
npm ERR! npm -v 1.3.8
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR!     /Users/luismartins/Sites/idomlive/protected/views/mail/modelos_base/npm-debug.log
npm ERR! not ok code 0

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.