reconfigure package for ts-only consumption
This commit is contained in:
20
package.json
20
package.json
@@ -4,34 +4,28 @@
|
||||
"version": "0.0.0",
|
||||
"scripts": {
|
||||
"dev": "vite dev",
|
||||
"build": "vite build && pnpm run prepack",
|
||||
"preview": "vite preview",
|
||||
"prepare": "svelte-kit sync || echo ''",
|
||||
"prepack": "svelte-kit sync && svelte-package && publint",
|
||||
"check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json",
|
||||
"check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch",
|
||||
"format": "prettier --write .",
|
||||
"lint": "prettier --check . && eslint ."
|
||||
},
|
||||
"files": [
|
||||
"dist",
|
||||
"!dist/**/*.test.*",
|
||||
"!dist/**/*.spec.*"
|
||||
"src/lib",
|
||||
"!src/lib/**/*.test.*",
|
||||
"!src/lib/**/*.spec.*"
|
||||
],
|
||||
"sideEffects": [
|
||||
"**/*.css"
|
||||
],
|
||||
"svelte": "./dist/index.js",
|
||||
"types": "./dist/index.d.ts",
|
||||
"svelte": "./src/lib/index.ts",
|
||||
"types": "./src/lib/index.ts",
|
||||
"type": "module",
|
||||
"exports": {
|
||||
"./internal": {
|
||||
".": {
|
||||
"types": "./src/lib/index.ts",
|
||||
"svelte": "./src/lib/index.ts"
|
||||
},
|
||||
".": {
|
||||
"types": "./dist/index.d.ts",
|
||||
"svelte": "./dist/index.js"
|
||||
}
|
||||
},
|
||||
"peerDependencies": {
|
||||
@@ -44,7 +38,6 @@
|
||||
"@jsrob/svelte-portal": "^0.2.1",
|
||||
"@svelte-toolkit/validate": "^0.0.0",
|
||||
"@sveltejs/adapter-auto": "^4.0.0",
|
||||
"@sveltejs/package": "^2.0.0",
|
||||
"@sveltejs/vite-plugin-svelte": "^5.0.0",
|
||||
"@tailwindcss/vite": "^4.0.0",
|
||||
"@types/node": "^24.0.9",
|
||||
@@ -61,7 +54,6 @@
|
||||
"prettier": "^3.4.2",
|
||||
"prettier-plugin-svelte": "^3.3.3",
|
||||
"prettier-plugin-tailwindcss": "^0.6.11",
|
||||
"publint": "^0.3.2",
|
||||
"svelte": "^5.0.0",
|
||||
"svelte-check": "^4.0.0",
|
||||
"typescript": "^5.0.0",
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
<script lang="ts">
|
||||
import type { Snippet } from 'svelte';
|
||||
import { validate } from '@svelte-toolkit/validate';
|
||||
import { generateIdentifier } from './util.js';
|
||||
import { generateIdentifier } from './util';
|
||||
import type { ClassValue } from 'svelte/elements';
|
||||
|
||||
interface Props {
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
import { Portal } from '@jsrob/svelte-portal';
|
||||
import { browser } from '$app/environment';
|
||||
import { scale } from 'svelte/transition';
|
||||
import { generateIdentifier } from './util.js';
|
||||
import { generateIdentifier } from './util';
|
||||
import type { ClassValue } from 'svelte/elements';
|
||||
|
||||
interface Props {
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
import { CalendarBlank } from 'phosphor-svelte';
|
||||
import { type Snippet } from 'svelte';
|
||||
import type { ClassValue, KeyboardEventHandler } from 'svelte/elements';
|
||||
import { generateIdentifier } from './util.js';
|
||||
import { generateIdentifier } from './util';
|
||||
import Label from './Label.svelte';
|
||||
|
||||
type FormatString = 'year' | 'month' | 'day';
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
import Combobox, { type ComboboxItem } from './Combobox.svelte';
|
||||
import StyledRawInput from './StyledRawInput.svelte';
|
||||
import { AsYouType, type PhoneNumber, type CountryCode } from 'libphonenumber-js';
|
||||
import { generateIdentifier } from './util.js';
|
||||
import { generateIdentifier } from './util';
|
||||
import type { ClassValue } from 'svelte/elements';
|
||||
|
||||
interface Props {
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import { isValueValid, validate, type ValidatorOptions } from '@svelte-toolkit/validate';
|
||||
import Label from './Label.svelte';
|
||||
import type { ClassValue } from 'svelte/elements';
|
||||
import { generateIdentifier } from './util.js';
|
||||
import { generateIdentifier } from './util';
|
||||
|
||||
interface Props {
|
||||
label?: string;
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
import { scale } from 'svelte/transition';
|
||||
import Label from './Label.svelte';
|
||||
import { validate } from '@svelte-toolkit/validate';
|
||||
import { getLabel, getValue, type Option } from './util.js';
|
||||
import { getLabel, getValue, type Option } from './util';
|
||||
|
||||
interface Props extends RadioGroupProps {
|
||||
options: Option[];
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
type InputValidatorEvent,
|
||||
type ValidatorOptions
|
||||
} from '@svelte-toolkit/validate';
|
||||
import { generateIdentifier } from './util.js';
|
||||
import { generateIdentifier } from './util';
|
||||
|
||||
type $Props = Omit<HTMLInputAttributes, 'name' | 'value'> & {
|
||||
name?: string;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import Label from './Label.svelte';
|
||||
import StyledRawInput from './StyledRawInput.svelte';
|
||||
import { type ValidatorOptions } from '@svelte-toolkit/validate';
|
||||
import { generateIdentifier } from './util.js';
|
||||
import { generateIdentifier } from './util';
|
||||
import type { ClassValue } from 'svelte/elements';
|
||||
|
||||
interface Props {
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
import { onMount } from 'svelte';
|
||||
import moment from 'moment';
|
||||
import type { ClassValue } from 'svelte/elements';
|
||||
import { generateIdentifier } from './util.js';
|
||||
import { generateIdentifier } from './util';
|
||||
|
||||
interface Props {
|
||||
name?: string;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import Label from './Label.svelte';
|
||||
import ToggleSelect from './ToggleSelect.svelte';
|
||||
import { validate, validateInput } from '@svelte-toolkit/validate';
|
||||
import { generateIdentifier, getLabel, getValue, type Option } from './util.js';
|
||||
import { generateIdentifier, getLabel, getValue, type Option } from './util';
|
||||
import type { ClassValue } from 'svelte/elements';
|
||||
|
||||
interface Props {
|
||||
|
||||
@@ -20,4 +20,4 @@ export { default as TimeInput } from './TimeInput.svelte';
|
||||
export { default as TimezoneInput } from './TimezoneInput.svelte';
|
||||
export { default as ToggleGroup } from './ToggleGroup.svelte';
|
||||
export { default as ToggleSelect } from './ToggleSelect.svelte';
|
||||
export { type Option, getLabel, getValue } from './util.js';
|
||||
export { type Option, getLabel, getValue } from './util';
|
||||
|
||||
@@ -9,7 +9,9 @@
|
||||
"skipLibCheck": true,
|
||||
"sourceMap": true,
|
||||
"strict": true,
|
||||
"module": "NodeNext",
|
||||
"moduleResolution": "NodeNext"
|
||||
"moduleResolution": "bundler",
|
||||
"declaration": true,
|
||||
"declarationMap": true,
|
||||
"isolatedModules": true
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user