@softlimit/theme-envy 0.1.4-alpha → 0.1.5-alpha

Sign up to get free protection for your applications and to get access to all the features.
@@ -69,7 +69,7 @@ function listFeaturesOrElements({ type }) {
69
69
  console.error(`The ${item} ${type} does not exist in the parent theme`)
70
70
  return
71
71
  }
72
- elementsOrFeatures.push(path.resolve(ThemeEnvy.parentTheme.path, 'theme-envy', type, item))
72
+ elementsOrFeatures.push(path.resolve(ThemeEnvy.parentTheme.path, 'src/theme-envy', type, item))
73
73
  }
74
74
  })
75
75
  }
@@ -10,8 +10,8 @@ const { directories } = require('#EnsureDirectories')
10
10
  // sets resolved parent theme path
11
11
  require('./index.js')
12
12
 
13
- module.exports = (func, childFiles, type) => {
14
- const childRelative = childFiles.map(file => path.relative(ThemeEnvy.themePath, file))
13
+ module.exports = (getFiles, childFiles, type) => {
14
+ const childRelative = childFiles.map(file => path.relative(process.cwd(), file))
15
15
  // get all files from the parent theme, using only elements and features directories in parent theme
16
16
  let only = [...ThemeEnvy.parentTheme.elements, ...ThemeEnvy.parentTheme.features]
17
17
 
@@ -42,6 +42,5 @@ module.exports = (func, childFiles, type) => {
42
42
  if (type === 'criticalCSS') {
43
43
  only.push(path.resolve(ThemeEnvy.parentTheme.path, 'src/styles'))
44
44
  }
45
-
46
- return func(ThemeEnvy.parentTheme.path, only).filter(file => !childRelative.includes(path.relative(ThemeEnvy.parentTheme.path, file)))
45
+ return getFiles(ThemeEnvy.parentTheme.path, only).filter(file => !childRelative.includes(path.relative(ThemeEnvy.parentTheme.path, file)))
47
46
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@softlimit/theme-envy",
3
- "version": "0.1.4-alpha",
3
+ "version": "0.1.5-alpha",
4
4
  "description": "Softlimit Shopify Theme Development Environment",
5
5
  "bin": {
6
6
  "theme-envy": "./index.js"
@@ -59,6 +59,11 @@
59
59
  "css-loader": "^6.7.3",
60
60
  "cssnano": "^5.1.15",
61
61
  "esbuild-loader": "^3.0.1",
62
+ "eslint": "^8.34.0",
63
+ "eslint-config-standard": "^17.0.0",
64
+ "eslint-plugin-import": "^2.27.5",
65
+ "eslint-plugin-n": "^15.6.1",
66
+ "eslint-plugin-promise": "^6.1.1",
62
67
  "fs-extra": "^11.1.0",
63
68
  "glob": "^10.2.1",
64
69
  "mini-css-extract-plugin": "^2.7.2",
@@ -78,11 +83,6 @@
78
83
  },
79
84
  "devDependencies": {
80
85
  "caller": "^1.1.0",
81
- "eslint": "^8.34.0",
82
- "eslint-config-standard": "^17.0.0",
83
- "eslint-plugin-import": "^2.27.5",
84
- "eslint-plugin-n": "^15.6.1",
85
- "eslint-plugin-promise": "^6.1.1",
86
86
  "jsdoc": "^4.0.2"
87
87
  }
88
88
  }