-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: use global config on templates
- Loading branch information
Showing
13 changed files
with
164 additions
and
92 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
{ | ||
"framework": "react", | ||
"cssFramework": "css_modules", | ||
"testFramework": "jest", | ||
"version": null, | ||
"name": "KebabCase", | ||
"resourcePath": "src/components", | ||
"testPath": "src/components", | ||
"storyPath": "src/components", | ||
"testPostfix": "spec", | ||
"storyPostfix": "stories", | ||
"type": "component", | ||
"typescript": true, | ||
"withStory": true, | ||
"withTest": true, | ||
"withTestingLibrary": true, | ||
"folderWrapper": false | ||
} |
This file was deleted.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
import { join } from 'node:path' | ||
import { readFileContent } from '../utils/file.js' | ||
import { getConfigContent } from '../utils/init-action.js' | ||
|
||
export async function coldStart() { | ||
const configPath = join(process.cwd(), 'clingon.config.json') | ||
|
||
/** | ||
* App data | ||
*/ | ||
const data = { | ||
/** | ||
* @type {import('../types').GlobalConfig | undefined} | ||
*/ | ||
globalConfig: undefined | ||
} | ||
|
||
try { | ||
const config = getConfigContent(configPath) | ||
|
||
if (config) { | ||
data.globalConfig = JSON.parse(config) | ||
} | ||
} catch (error) { | ||
console.error(error) | ||
} | ||
|
||
return data | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.