Skip to content

Commit

Permalink
docs: add jsdoc comments for Options interface
Browse files Browse the repository at this point in the history
  • Loading branch information
jorroll authored Apr 16, 2021
1 parent 6d5a31a commit 6f0cea9
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,36 @@ const runtimePublicPath = '/@solid-refresh';
const runtimeFilePath = require.resolve('solid-refresh/dist/solid-refresh.mjs');
const runtimeCode = readFileSync(runtimeFilePath, 'utf-8');

/** Configuration options for vite-plugin-solid. */
export interface Options {
/**
* This will inject solid-js/dev in place of solid-js in dev mode. Has no
* effect in prod. If set to `false`, it won't inject it in dev. This is
* useful for extra logs and debugging.
*
* @default true
*/
dev: boolean;
/**
* This will force SSR code in the produced files. This is experiemental
* and mostly not working yet.
*
* @default false
*/
ssr: boolean;
/**
* This will inject HMR runtime in dev mode. Has no effect in prod. If
* set to `false`, it won't inject the runtime in dev.
*
* @default true
*/
hot: boolean;
/**
* Pass any additional babel transform options. They will be merged with
* the transformations required by Solid.
*
* @default {}
*/
babel:
| TransformOptions
| ((source: string, id: string, ssr: boolean) => TransformOptions)
Expand Down

0 comments on commit 6f0cea9

Please sign in to comment.