Skip to content

Ignore newline semicolon for css files. #249

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Mar 15, 2018
Merged

Ignore newline semicolon for css files. #249

merged 5 commits into from
Mar 15, 2018

Conversation

jonkemp
Copy link
Owner

@jonkemp jonkemp commented Mar 10, 2018

Proposed fix to #241 and #248.

This would only apply the newline option when concatenating js files and leave css files alone ignore newline semicolon for css files. It turns out css files do not need this option. If they do, then we can come up with another solution. I want to make sure that is needed first though.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.01%) to 98.16% when pulling a6fa653 on newline into b06ecc5 on master.

1 similar comment
@coveralls
Copy link

Coverage Status

Coverage increased (+0.01%) to 98.16% when pulling a6fa653 on newline into b06ecc5 on master.

@coveralls
Copy link

coveralls commented Mar 10, 2018

Coverage Status

Coverage increased (+0.04%) to 98.193% when pulling 83c749a on newline into b06ecc5 on master.

index.js Outdated
@@ -75,6 +77,9 @@ function addAssetsToStream(paths, files) {

// option for newLine in gulp-concat
if (options.hasOwnProperty('newLine')) {
if (options.newLine === ';' && type === 'css') {
options.newLine = '';

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggest set options.newLine to null, as 'gulp-concat' checks type for string and ignores anything else.

@jonkemp jonkemp changed the title Apply newline to js files only. Ignore newline semicolon for css files. Mar 13, 2018
@jonkemp jonkemp merged commit 5661340 into master Mar 15, 2018
@jonkemp jonkemp deleted the newline branch March 15, 2018 02:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants