@herodevs/coulson
Advanced tools
Comparing version 0.0.8 to 0.0.9
{ | ||
"name": "@herodevs/coulson", | ||
"version": "0.0.8", | ||
"version": "0.0.9", | ||
"description": "Add coulson to your angular app", | ||
@@ -5,0 +5,0 @@ "scripts": { |
@@ -7,10 +7,11 @@ # Getting Started With Schematics | ||
To test locally, install `@angular-devkit/schematics-cli` globally and use the `schematics` command line tool. That tool acts the same as the `generate` command of the Angular CLI, but also has a debug mode. | ||
To test locally (dev in `safemode`), install `@angular-devkit/schematics-cli` globally and use the `schematics` command line tool. That tool acts the same as the `generate` command of the Angular CLI, but also has a debug mode. | ||
Check the documentation with | ||
```bash | ||
schematics --help | ||
``` | ||
npm run copy:generate | ||
cd schematics/coulson | ||
npm run schematics | ||
``` | ||
### Testing in a project | ||
### Testing in a project devMode | ||
@@ -31,2 +32,10 @@ ``` | ||
#### Testing in a project with npm | ||
For this test, first you need publish the schematics (see below), after this create an angular project. | ||
You can copy one of the seed project for test more fast. | ||
``` | ||
ng add @herodevs/coulson | ||
npm run coulson:generate | ||
``` | ||
### Unit Testing | ||
@@ -41,2 +50,4 @@ | ||
```bash | ||
npm run copy:generate | ||
cd schematics/coulson | ||
npm run build | ||
@@ -47,2 +58,2 @@ npm publish | ||
That's it! | ||
@@ -14,4 +14,9 @@ { | ||
"schema": "./coulson/schema.json" | ||
}, | ||
"add-component": { | ||
"description": "Add coulson component to your angular app.", | ||
"factory": "./add-component/index", | ||
"schema": "./add-component/schema.json" | ||
} | ||
} | ||
} | ||
} |
@@ -24,3 +24,5 @@ "use strict"; | ||
jsonContent.scripts['coulson:generate'] = `node node_modules/@herodevs/coulson/src/files`; | ||
jsonContent.dependencies['@herodevs/coulson-components'] = '0.0.1'; | ||
tree.overwrite(`/package.json`, JSON.stringify(jsonContent, undefined, 2)); | ||
context.addTask(new tasks_1.NodePackageInstallTask('./')); | ||
// add coulson files | ||
@@ -108,2 +110,3 @@ const sourceTemplates = schematics_1.url('./files'); | ||
context.logger.log('info', `🔍 Installing packages...`); | ||
// context.addTask(new RunSchematicTask('add-component', options)); | ||
return schematics_1.mergeWith(sourceParametrizedTemplates); | ||
@@ -110,0 +113,0 @@ }; |
@@ -15,3 +15,3 @@ { | ||
"noImplicitThis": true, | ||
"noUnusedParameters": true, | ||
"noUnusedParameters": false, | ||
"noUnusedLocals": true, | ||
@@ -22,3 +22,3 @@ "rootDir": "src/", | ||
"sourceMap": true, | ||
"strictNullChecks": true, | ||
"strictNullChecks": false, | ||
"target": "es6", | ||
@@ -34,4 +34,5 @@ "types": [ | ||
"exclude": [ | ||
"src/*/files/**/*" | ||
"src/*/files/**/*", | ||
"src/add-component/test/*" | ||
] | ||
} |
Sorry, the diff of this file is not supported yet
61841
68
889
56