Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"deploy": "git push -f upstream master:docs-v8",
"icons": "rimraf public/static/icons/* && node ./scripts/buildIcons.js",
"serve": "serve ./export -l 3010",
"create-playground": "cpy --cwd=scripts playground.template.tsx ../../pages/playground --rename=index.tsx",
"create-playground": "node ./scripts/createPlayground.js",
"typescript": "tsc -p tsconfig.json",
"typescript:transpile": "cross-env BABEL_ENV=development node scripts/formattedTSDemos",
"typescript:transpile:dev": "cross-env BABEL_ENV=development node scripts/formattedTSDemos --watch",
Expand Down
23 changes: 23 additions & 0 deletions docs/scripts/createPlayground.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
const fs = require('fs');
const path = require('path');

const sourceFile = path.join(__dirname, 'playground.template.tsx');
const targetFile = path.join(process.cwd(), 'pages/playground/index.tsx');
const targetDir = path.dirname(targetFile);

if (fs.existsSync(targetFile)) {
// eslint-disable-next-line no-console
console.log('File already exists, skipping copy\n');
process.exit(0);
}

try {
fs.mkdirSync(targetDir, { recursive: true });
fs.copyFileSync(sourceFile, targetFile);

// eslint-disable-next-line no-console
console.log('✅ File copied successfully\n');
} catch (error) {
console.error('❌ Error copying file:', error.message);
process.exit(1);
}
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,6 @@
"chai-dom": "^1.12.1",
"compression-webpack-plugin": "^11.1.0",
"concurrently": "^9.2.1",
"cpy-cli": "^5.0.0",
"cross-env": "catalog:",
"danger": "^13.0.4",
"date-fns-jalali-v2": "npm:[email protected]",
Expand Down
146 changes: 0 additions & 146 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading