Skip to content

Commit

Permalink
fix(watch): skip on build index.css changes
Browse files Browse the repository at this point in the history
  • Loading branch information
johannschopplich committed Sep 22, 2021
1 parent 7bd89d5 commit 411e87c
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ import { name, version } from '../package.json'
import type { Awaited } from 'ts-essentials'
import type { Options, NormalizedOptions } from './types'

const outFile = 'index.js'

export async function runViteBuild(options: NormalizedOptions) {
let result: Awaited<ReturnType<typeof viteBuild>> | undefined

Expand All @@ -25,7 +23,7 @@ export async function runViteBuild(options: NormalizedOptions) {
entry: resolve(currentDir, options.entry),
formats: ['iife'],
name: 'kirbyupExport',
fileName: () => outFile
fileName: () => 'index.js'
},
minify: !options.watch,
outDir: currentDir,
Expand Down Expand Up @@ -89,8 +87,8 @@ export async function build(_options: Options) {

const ignored = [
'**/{.git,node_modules}/**',
// Always ignore out file
outFile
// Always ignore out files
'index.{css,js}'
]

const watchPaths =
Expand Down

0 comments on commit 411e87c

Please sign in to comment.