Files
lucide/packages/lucide-solid/scripts/replaceVersion.mjs
Han Yeong-woo eb035fe370 Improve formatting (#1814)
* Ignore linting for examples in docs

* Formatting JSX single attribute per line

* Separte `format` and `lint:format` in package.json

* Bump prettier version

* Run format
2024-02-01 14:38:21 +01:00

14 lines
429 B
JavaScript

import fs from 'fs';
import path from 'path';
import pkg from '../package.json' assert { type: 'json' };
const files = ['dist/source/lucide-solid.js', 'dist/types/lucide-solid.d.ts'];
files.forEach((file) => {
const fileContents = fs.readFileSync(path.resolve(file), 'utf-8');
const newFileContents = fileContents.replace('{{version}}', pkg.version);
fs.writeFileSync(path.resolve(file), newFileContents, 'utf-8');
});