Security News
Node.js EOL Versions CVE Dubbed the "Worst CVE of the Year" by Security Experts
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Dalaran 是一个简单的前端开发环境,它可以帮助你简化 Webpack / Babel / Typescript / ESLint / TSLint / Karma / Mocha 配置。基本上,它可以接管你的开发调试、测试、Lint、打包过程。
Dalaran 是一个简单的前端开发环境,它可以帮助你简化 Webpack / Babel / Typescript / ESLint / TSLint / Karma / Mocha 配置。基本上,它可以接管你的开发调试、测试、Lint、打包过程。
$ npm install dalaran --save-dev
前端开发,通常包括两种:
调用 libraryTasks
来创建一些任务函数。我们提供了四个任务:dev
,build
,test
。
const dalaran = require('dalaran');
const tasks = dalaran.libraryTasks(options);
tasks.dev(); // 开启调试
tasks.build(); // 构建打包
tasks.test(); // 进行测试
参数名称 | 描述 | 类型 | 默认值 |
---|---|---|---|
port | 调试服务器端口 | Number | 3000 |
base | 项目根目录 | Sting | process.cwd() |
entry | 模块的入口文件 | String | './src/index.js' |
demo | demo 目录(调试时的入口文件) | String | './demo' |
dist | 打包文件的目录 | String | './dist' |
umdName | 模块的 UMD 名称 | String | 'foo' |
devSuffix | 调试时 bundle 的后缀名 | String | 'bundle' |
buildSuffix | 打包文件的后缀名 | String | 'min' |
react | 是否转译 JSX | Boolean | false |
loaders | 额外的 webpack loaders | Array | [] |
plugins | 额外的 webpack plugins | Array | [] |
babelPolyfill | 是否引入 babelPolyfill | Boolean | false |
devCors | 调试服务器是否开启 CORS | Boolean | true |
watchTest | 测试时是否开启 watch | Boolean | false |
testEntryPattern | 测试文件的匹配模式 | String | 'src/**/*.spec.js' |
lint | 是否开启 lint | Boolean | false |
lintrcDir | lint 配置文件存放目录 | String | process.cwd() |
minify | 打包时是否压缩 JS | Boolean | true |
liveReload | 调试时是否开启 livereload | Boolean | fasle |
typescript | 是否开启 Typescript | Boolean | false |
调用 applicationTasks
来创建一些任务函数。我们提供了四个任务:dev
,build
,test
。
const dalaran = require('dalaran');
const tasks = dalaran.applicationTasks(options);
tasks.dev(); // 开启调试
tasks.build(); // 构建打包
tasks.test(); // 进行测试
name | description | type | default |
---|---|---|---|
port | 调试服务器端口 | Number | 3000 |
base | 项目根目录 | Sting | process.cwd() |
demo | demo 目录(调试时的入口文件) | String | './demo' |
dist | 打包文件的目录 | String | './dist' |
devSuffix | 调试时 bundle 的后缀名 | String | 'bundle' |
buildSuffix | 打包文件的后缀名 | String | 'bundle' |
react | 是否转译 JSX | Boolean | false |
loaders | 额外的 webpack loaders | Array | [] |
plugins | 额外的 webpack plugins | Array | [] |
babelPolyfill | 是否引入 babelPolyfill | Boolean | false |
devCors | 调试服务器是否开启 CORS | Boolean | true |
watchTest | 测试时是否开启 watch | Boolean | false |
testEntryPattern | 测试文件的匹配模式 | String | 'src/**/*.spec.js' |
publicPath | 部署时的 publicPath | String | './' |
lint | 是否开启 lint | Boolean | false |
minify | 打包时是否压缩 JS | Boolean | true |
liveReload | 调试时是否开启 livereload | Boolean | fasle |
typescript | 是否开启 Typescript | Boolean | false |
FAQs
Dalaran 是一个简单的前端开发环境,它可以帮助你简化 Webpack / Babel / Typescript / ESLint / TSLint / Karma / Mocha 配置。基本上,它可以接管你的开发调试、测试、Lint、打包过程。
The npm package dalaran receives a total of 78 weekly downloads. As such, dalaran popularity was classified as not popular.
We found that dalaran demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.