clases-tailwind 1.0.2 → 1.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "clases-tailwind",
3
- "version": "1.0.2",
3
+ "version": "1.0.4",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
@@ -15,7 +15,6 @@
15
15
  },
16
16
  "scripts": {
17
17
  "build": "tsup src/index.ts --format cjs,esm --dts --clean",
18
- "dev": "tsup src/index.ts --format cjs,esm --dts --watch",
19
- "postinstall": "node scripts/init.js"
18
+ "dev": "tsup src/index.ts --format cjs,esm --dts --watch"
20
19
  }
21
20
  }
@@ -1,26 +0,0 @@
1
- const fs = require('fs');
2
- const path = require('path');
3
-
4
- const projectRoot = process.env.INIT_CWD || path.resolve('../../');
5
- const hasSrc = fs.existsSync(path.join(projectRoot, 'src'));
6
- const targetDir = hasSrc ? path.join(projectRoot, 'src') : projectRoot;
7
- const configPath = path.join(targetDir, 'clases.config.ts');
8
-
9
- const tailwindTemplate = `import { createCl } from 'clases';
10
- import { tailwindRegistry } from 'clases-tailwind';
11
-
12
- // Instancia configurada para Tailwind CSS
13
- export const tw = createCl(tailwindRegistry);
14
- `;
15
-
16
- try {
17
- // En este caso, SIEMPRE queremos que si instalan clases-tailwind,
18
- // el archivo tenga la configuración de Tailwind.
19
- fs.writeFileSync(configPath, tailwindTemplate, 'utf8');
20
- console.log(
21
- '\x1b[32m%s\x1b[0m',
22
- ' [clases-tailwind] Configuración vinculada con éxito en ' + (hasSrc ? 'src/' : './')
23
- );
24
- } catch (err) {
25
- console.log(' [clases-tailwind] Aviso: No se pudo auto-configurar el archivo.');
26
- }