firescript-config
v0.5.0
Published
Config module for Firescript
Downloads
22
Maintainers
Readme
Firescript config
Firescript config module.
Usage
import { FirescriptConfig } from 'firescript-config'
const config = new FirescriptConfig({
srcDir: `${process.cwd()}/src/`,
destDir: `${process.cwd()}/dist/`
})
Methods
loadConfig([str filename]) => obj config
Load config from a config file
const config = await config.loadConfig()
console.log('Config:', config)
Arguments:
| Name: | Flags: | Description: |
| ---------- | ---------- | ----------------------- |
| filename | optional
| Load config from a file |
Returns:
Returns an instance of FirescriptConfig
Config parameters
| Name: | Config param: | Default value: | Description: |
| --------- | ------------- | -------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| srcDir | build.src
| src/
| Project source dir |
| destDir | build.dist
| dist/
| Project destination dir |
| copyFiles | build.copy
| []
| Copy files from srcDir
or projectRoot
to destionation
. The parser looks for files in the source
dir first, if no file was fount it looks into the projectRoot
. You can omit this behavior by adding $ROOT/
as a prefix to the path. |
| | | | |