@reactful/create 0.0.55 → 0.0.57

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. package/index.js +4 -2
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -1,10 +1,10 @@
1
1
  #!/usr/bin/env node
2
2
 
3
+ import { exec } from 'child_process'
3
4
  import inquirer from 'inquirer'
4
5
  import path from 'path'
5
6
  import fs from 'fs'
6
7
 
7
- const { exec } = require('child_process');
8
8
 
9
9
  const GREEN = '\x1b[32m';
10
10
  const RESET = '\x1b[0m';
@@ -16,7 +16,9 @@ console.log(line)
16
16
  console.log(`${decor}( ${GREEN}reactful${RESET}.js )${decor}`)
17
17
  console.log(line)
18
18
 
19
- const templatePath = path.join(process.cwd(), 'templates')
19
+ const nodeModulesPath = 'node_modules/@reactful/create'
20
+
21
+ const templatePath = path.join(process.cwd(), nodeModulesPath, 'templates')
20
22
 
21
23
  const templates = fs.readdirSync(templatePath)
22
24
  .map(x => ({ name:x, path: `${templatePath}/${x}`}))
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reactful/create",
3
- "version": "0.0.55",
3
+ "version": "0.0.57",
4
4
  "main": "index.js",
5
5
  "type": "module",
6
6
  "description": "reactful scafold tool",