Code Monkey home page Code Monkey logo

broccoli-less-single's People

Contributors

dependabot[bot] avatar elberet avatar gabrielgrant avatar gpoitch avatar jasonmit avatar luto avatar mkempe avatar simonihmig avatar stefanpenner avatar tilleps avatar txm avatar vuiets avatar webark avatar

Stargazers

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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

broccoli-less-single's Issues

Not respecting outputPaths config in Brocfile.js

i'm using ember-cli 0.1.5,

I'd like to build a css file for each 'skin-*.less' file in the app/styles folder. This works with plain CSS using the following config in my Brocfile.js:

var app = new EmberApp({
    outputPaths: {
        app: {
            css: {
                'skin-light': '/assets/skin-light.css',
                'skin-dark': '/assets/skin-dark.css'
            }
        }
    }
});

After installing the LESS precompiler with 'ember install:addon ember-cli-less' this config is not respected and instead 'ember build' looks for app/styles/app.less.

Error with broccoli 0.7.2

Hi there, thank you for creating broccoli-less-single. Unfortunately, it fails with an error if you use it with broccoli 0.7.2, while it works fine with 0.5.x (didn't check 0.6.x, sorry):

Object #<TreeMerger> has no method 'reduce' TypeError: Object #<TreeMerger> has no method 'reduce'
    at promiseMapSeries (/path/to/project/node_modules/broccoli-less-single/node_modules/promise-map-series/index.js:6:16)
    at LessCompiler.read (/path/to/project/node_modules/broccoli-less-single/index.js:25:10)
    at readTree (/path/to/project/node_modules/broccoli/lib/builder.js:61:20)
    at promise.then.then.results.(anonymous function) (/path/to/project/node_modules/broccoli-merge-trees/node_modules/promise-map-series/index.js:8:27)
    at invokeCallback (/path/to/project/node_modules/broccoli-merge-trees/node_modules/promise-map-series/node_modules/rsvp/dist/commonjs/rsvp/promise.js:228:21)
    at publish (/path/to/project/node_modules/broccoli-merge-trees/node_modules/promise-map-series/node_modules/rsvp/dist/commonjs/rsvp/promise.js:176:9)
    at publishFulfillment (/path/to/project/node_modules/broccoli-merge-trees/node_modules/promise-map-series/node_modules/rsvp/dist/commonjs/rsvp/promise.js:312:5)
    at flush (/path/to/project/node_modules/broccoli-merge-trees/node_modules/promise-map-series/node_modules/rsvp/dist/commonjs/rsvp/asap.js:41:9)
    at process._tickCallback (node.js:415:13)

Fix Travis CI

Some upgrade in Travis CI broke the auto npm deployments. This needs to be investigated and fixed.

Source map files are created even when only inline source maps are requested

Less.js supports inline source maps with the options hash { sourceMap: { sourceMapFileInline: true } }. Unfortunately, the options handler detects the presence of sourceMap and implicitly and unconditionally fills in sourceMap.sourceMapURL which during the build step causes the source map to be written to its own file despite Less.js having already generated the inline map.

I've already fixed this in a fork, PR incoming. ๐Ÿ™‚

Better error handling

Having syntax errors in your less causes ember-cli server to crash. This also happens when you import less files that don't exist yet.

file changed editor.less
file changed styles/editor.less
ParseError: Unrecognised input in .../tmp/tree_merger-tmp_dest_dir-W7qmEPWo
.tmp/app/styles/editor.less on line 19, column 9:
18         height: 100px; 
19         background-color #cccccc;
20       }

var css = tree.toCSS(lessOptions);                                                                          
TypeError: Cannot call method 'toCSS' of undefined

cc @rjackson @stefanpenner

Working example?

I'm having difficulty getting this working. I am 99% confident it is my fault, and incomplete understanding of one of the various tools involved.

So this is a request for something that would solve my problem and perhaps many others':

Include a complete working example in the repo or in the README. For optimal ease, have this example use Bootstrap in Less form, as that is probably the most common reason someone would come looking for this plug-in.

High vulnerability in dependency (lodash.merge)

yarn audit output includes the following:

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚ high          โ”‚ Prototype Pollution                                          โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚ Package       โ”‚ lodash.merge                                                 โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚ Patched in    โ”‚ >=4.6.2                                                      โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚ Dependency of โ”‚ [other package]                                              โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚ Path          โ”‚ [other packages] > broccoli-less-single > lodash.merge       โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚ More info     โ”‚ https://www.npmjs.com/advisories/1066                        โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ดโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

The package.json specifies "lodash.merge": "^3.3.2" so (assuming the updated version is compatible) a major version bump is required to overcome.

Tests

Having some simple testing would make it a little easier to quickly merge PRs. Just a couple end-to-end smoke tests would be a good start.

rebuilding despite no .less file changes

This continues discussion here #31.
As a developer, I expect the less compiler to execute only when I change a less file in my project. This appears to not be the case. I took the following screenshot of performance output from ember-cli while running ember server and changing an .hbs file.
screen shot 2018-10-31 at 11 30 33

 npm ls broccoli-less-single

myproject
โ””โ”€โ”ฌ [email protected]
  โ””โ”€โ”€ [email protected]
ember-cli: 3.5.0
node: 8.11.4
os: darwin x64

Please add example of @import / @include

The readme mentions @include as the way to include other files, but

  1. It's surprising that it's @include and not the Less-like @import
  2. I can't get this to work (seems the @include and @import macros are ignored), but there's no examples to refer to on the README.

This could all be cleared up with just a quick example .less file in the README for a quick sanity check.

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.