@patternplate/create-default
Advanced tools
Comparing version 2.0.0-y.0 to 2.0.0
42
index.js
@@ -25,32 +25,23 @@ module.exports = createDefault; | ||
const README = data => { | ||
return ` | ||
> a patternplate project | ||
return `--- | ||
displayName: "my-patternplate" | ||
--- | ||
# ${data.name} | ||
# You did it! :tada: | ||
* Documentation at \`docs\` | ||
* Pattern sources at \`lib\` | ||
You successfully installed and started patternplate. | ||
## Getting started | ||
Head back to the [Getting Started Guide](https://patternplate.github.io/doc/docs/guides/getting-started#up-next) for further instructions. | ||
\`\`\`bash | ||
yarn | ||
yarn patternplate | ||
\`\`\ | ||
`; | ||
} | ||
## Up next | ||
const DOCS = data => { | ||
return `--- | ||
displayName: Documentation | ||
options: | ||
order: -1 | ||
--- | ||
* [Guide: Build a component](https://patternplate.github.io/doc/docs/guides/add-component) | ||
> a patternplate project | ||
# ${data.name} | ||
` | ||
}; | ||
## Related topics | ||
* [CLI](https://patternplate.github.io/doc/docs/reference/cli) | ||
`; | ||
} | ||
const PATTERN_JSON = data => { | ||
@@ -70,4 +61,4 @@ return JSON.stringify({ | ||
module.exports = { | ||
html: '<h1 class="hello-world" data-hello-world>Hello World</h1>', | ||
css: '.hello-world { font-family: sans-serif; color: cornflowerblue; cursor: pointer; }', | ||
html: () => '<h1 class="hello-world" data-hello-world>Hello World</h1>', | ||
css: () => '.hello-world { font-family: sans-serif; color: cornflowerblue; cursor: pointer; }', | ||
default: function() { | ||
@@ -90,5 +81,2 @@ var el = document.querySelector("[data-hello-world]"); | ||
fs.mkdirpSync("/docs"); | ||
fs.writeFileSync("/docs/docs.md", DOCS(data)); | ||
fs.mkdirpSync("/lib/hello-world"); | ||
@@ -95,0 +83,0 @@ fs.writeFileSync("/lib/hello-world/package.json", PATTERN_JSON(data)); |
{ | ||
"name": "@patternplate/create-default", | ||
"version": "2.0.0-y.0", | ||
"version": "2.0.0", | ||
"description": "Create a default patternplate project via patternplate create", | ||
@@ -5,0 +5,0 @@ "xo": false, |
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
2790
1
80