Couldn't load imported Less file 1) with a period in it's name and 2) without extension
See original GitHub issueHi,
I just upgraded from v1.3.0 to v1.3.3 and ran into an issue with importing a Less file named chained.banner.less
. I always import Less files without an extension, ie. @import "chained.banner";
and apparently v1.3.3 guesses that .banner
is the extension.
Swapping the period in the file name for a dash (ie. chained-banner.less
), adding a non a-z character to the 2nd part of the file name (ie. chained.banner123.less
) or adding the extension to the import (ie. @import "chained.banner.less";
) seemed valid workarounds.
Issue Analytics
- State:
- Created 10 years ago
- Comments:14 (7 by maintainers)
Top Results From Across the Web
Why can't I import .less files into a single .less file?
I just tried this on my local environment, putting vars into vars.less and mixins into conf.less . The file structure similar to yours,...
Read more >Review and troubleshoot import errors - Knowledge Base
Learn how to view and troubleshoot common errors that occur during record imports.
Read more >Error message when you open or save a file in Microsoft Excel
If you are trying to open the file from your list of most recently used files on the File menu, make sure that...
Read more >Chapter 14: SOLUTIONS TO TEXT PROBLEMS:
2. The price faced by a profit-maximizing firm is equal to its marginal cost ... Both allow firms or individuals to be monopolies...
Read more >A Basic Guide to Exporting - International Trade Administration
the smaller the company, the less likely it is to export to more than one country. ... Did import growth occur even during...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@r-wettstaedt It was not a bug then and it’s not a bug now. Less is not supposed to auto-append
less
extension in this case because the name already looks like having a one (=min
). See File Extensions for more details. The proper import should be:in this case.
Note the
(less)
option is implied by default, it’s implicitly required only when the extension of the imported file directly assumes another importing behaviour (e.g.foo.css
). And neither of importing options affect the auto-appending of extensions, i.e. it’s always:foo
->foo.less
foo.bar
->foo.bar
foo.css
->foo.css
foo.less
->foo.less
etc. and so on regardless of any options after the@import
statement. (The options control only how the file is imported and not what file name it has).@seven-phases-max, thanks for your explanation. I guess I gotta talk to the plugin developers then.