Path
Variables
$aliases
Variable Type: Map
- Important: alias could be used for directory or file so omit trailing slash for directories
- All aliases must start with "#"
Aliases
$aliases: (
"#Images" : "/images",
);
File Information
- File: _path.scss
- Group: path
- Type: variable
- Lines (comments): 9-12
- Lines (code): 14-16
Mixins
set-aliases()
Mixin
Set aliases or change defaults
File Information
- File: _path.scss
- Group: path
- Type: mixin
- Lines (comments): 18-19
- Lines (code): 21-23
Parameters
Name | Type | Description |
---|---|---|
$changes | Map |
Map of changes |
Require
Functions
get-alias()
Function
Get an aliases path
File Information
- File: _path.scss
- Group: path
- Type: function
- Lines (comments): 25-26
- Lines (code): 28-30
Parameters
Name | Type | Description |
---|---|---|
$Name | String |
Name of alias |
Require
- require-map-get()
- $aliases
resolve()
Function
Resolves a Path
- Checks if path is an alias if so rewrite's it
- Future could include rewrites for easier updating or rearranging of legacy things
- Aliases work by starting with "#", Since it's an illegal uri character, needs to be escaped if used as literal, we felt that it was the safest way to mix aliases in with real URLs (so that a dev of a module using path.resolve can always pass paths through (user input unknown if alias)
File Information
- File: _path.scss
- Group: path
- Type: function
- Lines (comments): 32-40
- Lines (code): 42-58
Examples
.img {
background-image: url(ulu.path-resolve("#Images/branding/logo"));
}