How to remove dependency on another file?
See original GitHub issueThe project suggests that the user will be able to change the design of the blocks without editing the core of the module. That’s how it works on IMPORT. Simple and understandable, as in any programming language.
##### You can edit files
// design1.scss
$a: red;
// design2.scss
$a: green;
// style.scss
@import 'design1';
// or
// @import 'design2';
@import 'core';
##### You can not edit
// core.scss
.d { color: $a }
With using USE, it is necessary to explicitly prescribe a module with variables in the core of the module. This creates dependence on another file and does not allow them to manage.
# You can edit files #
// style.scss
@use 'design1';
// or
// @use 'design2';
@use 'core';
# You can not edit #
// core.scss
@use 'design1' as design; // !!! incorrect - depends on another file !!!
.d { color: design.$a }
How to make the user change the design only in the style.scss file? Without editing the core.scss file.
Issue Analytics
- State:
- Created 3 years ago
- Comments:12 (5 by maintainers)
Top Results From Across the Web
Remove file from dependency jar using maven - Stack Overflow
unzip the war in a temp directory · unzip the dependency in another temp directory · delete the file from the dependency ·...
Read more >To Remove File Dependencies
Right-click the dependent child file and select Unlink Dependency. When the Remove Dependent File Link dialog opens, click Yes. The file dependency is...
Read more >How to: Create and remove project dependencies - Visual ...
To remove dependencies from projects · In Solution Explorer, select a project. · On the Project menu, choose Project Dependencies. · On the ......
Read more >Uninstalling packages and dependencies - npm Docs
To remove a package from your node_modules directory, on the command line, use the uninstall command. Include the scope if the package is...
Read more >Removing Dependencies: One Weird Trick for Increasing ...
Code in an unmaintained dependency may either stop compiling or, more often, cause compilation warnings because of deprecations. These ...
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
The problem is that IMPORT does not interfere with anyone and works without any problems. USE creates its scope that is not always needed by developers. In other programming languages, if you need an area of visibility, it sets where it is in demand.
The main goal is convenience for users. For example, in my projects there are more than 50 variables that are easily overlapped through the IMPORT in two lines of code. With USE is impossible to do this.
Maybe you should consider the opinion of those who use Sass in their projects? And not to close inconvenient ticket? If you really want modularity in Sass, it may be worth making instructions for a global scope as it works now?
Sorry for GoogleTranslate
hi, got stuck with scoped
@import
s and also am not sure about migrating bourbon library