@figma-export/output-components-as-es6
Advanced tools
Comparing version 0.0.1-alpha.4 to 0.0.1-alpha.5
13
index.js
@@ -9,8 +9,3 @@ const fs = require('fs'); | ||
module.exports = (options) => { | ||
if (!fs.existsSync(options.output)) { | ||
const err = new Error(`Folder '${options.output}' doesn't exist`); | ||
throw err; | ||
} | ||
module.exports = ({ output }) => { | ||
return async (pages) => { | ||
@@ -28,7 +23,5 @@ let code = ''; | ||
fs.writeFile(path.resolve(options.output, 'figma-components.js'), code, | ||
(err) => { | ||
if (err) throw err; | ||
}); | ||
const filePath = path.resolve(output, 'figma-components.js'); | ||
fs.writeFileSync(filePath, code); | ||
}; | ||
}; |
{ | ||
"name": "@figma-export/output-components-as-es6", | ||
"version": "0.0.1-alpha.4", | ||
"version": "0.0.1-alpha.5", | ||
"description": "Outputter for @figma-export that exports components in javascript file", | ||
@@ -16,3 +16,3 @@ "main": "index.js", | ||
}, | ||
"gitHead": "9a33a26c15abdb56385cb4430c5dd81218e7f75f" | ||
"gitHead": "50c474ee19e7b9e91a6cb941bc22f883181cba6d" | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
2729
4
47
2