Skip to content

Commit

Permalink
Build with vite
Browse files Browse the repository at this point in the history
  • Loading branch information
rushi committed Dec 21, 2024
1 parent 33fa16f commit f116415
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 56 deletions.
56 changes: 1 addition & 55 deletions src/icons/package-lock.json

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

8 changes: 7 additions & 1 deletion src/icons/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,14 @@
"name": "@xola/icons",
"version": "1.1.4",
"description": "Xola's icon set",
"main": "./index.js",
"files": [
"build",
"icons.es.js"
],
"main": "build/icons.es.js",
"module": "build/icons.es.js",
"scripts": {
"build": "vite build",
"format": "prettier --write -l src",
"lint": "xola-lint src",
"lint:fix": "xola-lint --fix src"
Expand Down
16 changes: 16 additions & 0 deletions src/icons/vite.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import path from "path";

Check failure on line 1 in src/icons/vite.config.js

View workflow job for this annotation

GitHub Actions / View Lint Report

src/icons/vite.config.js#L1

[unicorn/prefer-node-protocol] Prefer `node:path` over `path`.
import { defineConfig } from "vite";
import pkg from "./package.json";

Check failure on line 3 in src/icons/vite.config.js

View workflow job for this annotation

GitHub Actions / View Lint Report

src/icons/vite.config.js#L3

[@typescript-eslint/no-unused-vars] 'pkg' is defined but never used.

export default defineConfig({
build: {
outDir: "build",

lib: {
entry: path.resolve(__dirname, "./index.js"),

Check failure on line 10 in src/icons/vite.config.js

View workflow job for this annotation

GitHub Actions / View Lint Report

src/icons/vite.config.js#L10

[unicorn/prefer-module] Do not use "__dirname".
name: "XolaIcons",
fileName: (format) => `icons.${format}.js`,
formats: ["es"]

Check failure on line 13 in src/icons/vite.config.js

View workflow job for this annotation

GitHub Actions / View Lint Report

src/icons/vite.config.js#L13

[prettier/prettier] Insert `,`
},
}

Check failure on line 15 in src/icons/vite.config.js

View workflow job for this annotation

GitHub Actions / View Lint Report

src/icons/vite.config.js#L15

[prettier/prettier] Insert `,`
});

0 comments on commit f116415

Please sign in to comment.