Defining new handles
There are only two real rules for defining custom path handles:
- A path handle must be unique
- A path handle must be a
stringwhich begins with a
To make a reference to the
./src/scripts/components directory we could write:
In the future we can utilize that reference:
bud.path('@components') // => './src/scripts/components'
Overriding existing handles
We can redefine the path to source assets like so:
Lastly, we can define multiple paths (built-in or custom) in a single call by using an object:
Note that if we were to change
@src again that
@components path would still reference the old value. This is something to be aware of.