setup a eslint/prettier setup with plugins, and a basic webpack setup
This commit is contained in:
15
xclap.ts
15
xclap.ts
@@ -1,12 +1,19 @@
|
||||
const { load, exec, concurrent, serial } = require('@xarc/run');
|
||||
/* eslint-disable @typescript-eslint/no-unsafe-call */
|
||||
/* eslint-disable @typescript-eslint/no-unsafe-assignment */
|
||||
/* eslint-disable @typescript-eslint/no-var-requires */
|
||||
const { load, exec, serial } = require('@xarc/run');
|
||||
|
||||
load({
|
||||
build: ['postinstall', exec('gulp'), 'prettier'],
|
||||
build: [serial('postinstall', exec('gulp'), 'webpack', 'prettier'), 'webpack'],
|
||||
clean: exec('rimraf public coverage vendor'),
|
||||
prettier: [exec('prettier --write .')],
|
||||
lint: ['prettier'],
|
||||
'clean:webpack': exec('rimraf dist'),
|
||||
eslint: exec('eslint src . --fix'),
|
||||
lint: ['prettier', 'eslint'],
|
||||
postinstall: ['clean', exec('gulp postinstall')],
|
||||
prettier: [exec('prettier --write .')],
|
||||
test: ['build', 'lint', 'test-jest', 'test-js'],
|
||||
'test-jest': [exec('jest --clearCache'), exec('jest --verbose --coverage')],
|
||||
'test-js': 'phantomjs tests/run.js',
|
||||
webpack: ['clean:webpack', exec('webpack --mode production')],
|
||||
'webpack:dev': ['clean:webpack', exec('webpack --mode development')],
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user