Fixed build issues
Some checks failed
armco-org/utils/pipeline/head There was a failure building this commit
Some checks failed
armco-org/utils/pipeline/head There was a failure building this commit
This commit is contained in:
8
.gitignore
vendored
8
.gitignore
vendored
@@ -2,16 +2,12 @@ dist
|
||||
node_modules
|
||||
build
|
||||
HOC
|
||||
adapters
|
||||
chartGenerators
|
||||
contexts
|
||||
dateHelper
|
||||
dateformat
|
||||
domHelper
|
||||
gridHelper
|
||||
helper
|
||||
hooks
|
||||
network
|
||||
providers
|
||||
recursionHelper
|
||||
validators
|
||||
react-app-env.d
|
||||
.vscode
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"name": "@armco/utils/react-app-env.d",
|
||||
"main": "../build/cjs/react-app-env.d.js",
|
||||
"module": "../build/es/react-app-env.d.js",
|
||||
"types": "../build/types/react-app-env.d.d.ts"
|
||||
}
|
||||
@@ -1,7 +1,6 @@
|
||||
export * from "./domHelper"
|
||||
export * from "./helper"
|
||||
export * from "./network"
|
||||
export * from "../../taskerclient/src/validators"
|
||||
export * from "./recursionHelper"
|
||||
export * from "./hooks"
|
||||
export * from "./contexts"
|
||||
|
||||
16
src/types.ts → src/types.d.ts
vendored
16
src/types.ts → src/types.d.ts
vendored
@@ -1,6 +1,16 @@
|
||||
import { CSSProperties, ReactNode } from "react"
|
||||
import { ArAlertType } from "./enums"
|
||||
import { BaseProps, FunctionType } from "@armco/types"
|
||||
import { ReactNode } from "react"
|
||||
import { BaseProps, FunctionType, PanelContent, User } from "@armco/types"
|
||||
import { ArAlertType, ArThemes } from "./enums"
|
||||
|
||||
export interface AlertProps extends BaseProps {
|
||||
closeable?: boolean
|
||||
position?: string
|
||||
show?: boolean
|
||||
type?: ArAlertType
|
||||
message: string | ReactNode
|
||||
timeout?: number
|
||||
uid: string
|
||||
}
|
||||
|
||||
export interface DrawerProps extends BaseProps {
|
||||
children?: ReactNode
|
||||
@@ -23,5 +23,5 @@
|
||||
},
|
||||
"include": [
|
||||
"src"
|
||||
, "../taskerclient/src/validators.ts" ],
|
||||
],
|
||||
}
|
||||
|
||||
@@ -1,42 +0,0 @@
|
||||
import { resolve } from "node:path"
|
||||
import { glob } from "glob"
|
||||
import { defineConfig } from "vitest/config"
|
||||
import react from "@vitejs/plugin-react"
|
||||
import dts from "vite-plugin-dts"
|
||||
import { externalizeDeps } from "vite-plugin-externalize-deps"
|
||||
|
||||
// https://vitejs.dev/config/
|
||||
export default defineConfig({
|
||||
plugins: [react(), dts({ outDir: "build/types" }), externalizeDeps()],
|
||||
build: {
|
||||
outDir: "build",
|
||||
sourcemap: true,
|
||||
lib: {
|
||||
entry: glob.sync(resolve(__dirname, "src/**/*.{ts,tsx}")),
|
||||
},
|
||||
rollupOptions: {
|
||||
treeshake: true,
|
||||
external: [
|
||||
new RegExp("^react.*"),
|
||||
new RegExp("^@armco/.*"),
|
||||
"@armco/icon",
|
||||
"uuid",
|
||||
"d3",
|
||||
],
|
||||
output: [
|
||||
{
|
||||
format: "es",
|
||||
dir: "build/es",
|
||||
entryFileNames: "[name].js",
|
||||
chunkFileNames: "[name].js",
|
||||
},
|
||||
{
|
||||
format: "cjs",
|
||||
dir: "build/cjs",
|
||||
entryFileNames: "[name].js",
|
||||
chunkFileNames: "[name].js",
|
||||
},
|
||||
],
|
||||
},
|
||||
},
|
||||
})
|
||||
@@ -7,11 +7,20 @@ import { externalizeDeps } from "vite-plugin-externalize-deps"
|
||||
|
||||
// https://vitejs.dev/config/
|
||||
export default defineConfig({
|
||||
plugins: [react(), dts({ outDir: "build/types" }), externalizeDeps()],
|
||||
plugins: [
|
||||
react(),
|
||||
dts({
|
||||
outDir: "build/types",
|
||||
// Ensure types land directly under build/types without extra utils/src nesting
|
||||
root: resolve(__dirname),
|
||||
entryRoot: resolve(__dirname, "src"),
|
||||
}),
|
||||
externalizeDeps(),
|
||||
],
|
||||
build: {
|
||||
outDir: "build",
|
||||
lib: {
|
||||
entry: glob.sync(resolve(__dirname, "src/**/*.{ts,tsx}")),
|
||||
entry: glob.sync(resolve(__dirname, "src/**/!(*.d).{ts,tsx}")),
|
||||
},
|
||||
rollupOptions: {
|
||||
treeshake: true,
|
||||
|
||||
Reference in New Issue
Block a user