@atls/code-schematics 2.1.0 → 2.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5,9 +5,14 @@ import { apply } from '@angular-devkit/schematics';
5
5
  import { url } from '@angular-devkit/schematics';
6
6
  import { template } from '@angular-devkit/schematics';
7
7
  import { move } from '@angular-devkit/schematics';
8
+ const templateTypes = {
9
+ library: 'libraries',
10
+ project: 'project',
11
+ };
8
12
  export const generateProjectSpecificSource = (options) => {
9
13
  const { name: projectName } = JSON.parse(readFileSync(join(options.cwd, 'package.json'), 'utf-8'));
10
- return apply(url(join('../templates', options.type)), [
14
+ const templateType = templateTypes[options.type] ?? options.type;
15
+ return apply(url(join('../templates', templateType)), [
11
16
  template({
12
17
  ...strings,
13
18
  ...options,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atls/code-schematics",
3
- "version": "2.1.0",
3
+ "version": "2.2.0",
4
4
  "license": "BSD-3-Clause",
5
5
  "type": "module",
6
6
  "exports": {