feat: refactoring project

This commit is contained in:
Carlos
2024-11-23 14:56:07 -05:00
parent f0c2a50c18
commit 1c6db5818d
2351 changed files with 39323 additions and 60326 deletions

View File

@@ -0,0 +1,27 @@
// Placeholder for packageJson.js
function updatePackageJson() {
const spinner = ora(
'📝 Updating package.json with custom scripts...'
).start();
const packageJsonPath = path.resolve('package.json');
const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, 'utf8'));
packageJson.scripts = {
start: 'webpack serve --config webpack.config.js --mode development',
build: 'webpack --config webpack.config.js --mode production',
test: 'echo "Error: no test specified" && exit 0',
'test:dev': 'react-scripts test',
'pretty-quick': 'pretty-quick',
'lint:prettier': 'node check-format.js',
prettier: 'prettier --write . --config .prettierrc',
'prettier:commit': 'node prettier-commit.js',
eject: 'react-scripts eject',
prepare: 'husky install',
};
fs.writeFileSync(packageJsonPath, JSON.stringify(packageJson, null, 2));
spinner.succeed('📝 package.json updated with custom scripts.');
}
module.exports = { updatePackageJson };