Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(core/options): BREAKING CHANGE cache is disabled by default #223

Merged
merged 1 commit into from
Jul 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/unplugin-typia/src/core/options.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ export type Options = {
* The cache-dir-searching feature is powered by [find-cache-dir](https://github.com/sindresorhus/find-cache-dir). If you want to change cache dir, set an environment variable `CACHE_DIR`.
* if `true`, it will enable cache with and will use node_modules/.cache/unplugin_typia.
* if `false`, it will disable cache.
* @default true
* @default false
*/
cache?: true | false;

Expand All @@ -68,7 +68,7 @@ export const defaultOptions = ({
exclude: [/node_modules/],
enforce: 'pre',
typia: { },
cache: true,
cache: false,
log: true,
tsconfig: undefined,
}) as const satisfies ResolvedOptions;
Expand Down
2 changes: 1 addition & 1 deletion packages/unplugin-typia/test/options.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,5 +43,5 @@ test('Return cache is true if cache key is true', () => {

test('Return cache is true if cache key is not passed', () => {
const options = resolveOptions({});
assertEquals(options.cache, true);
assertEquals(options.cache, false);
});
Loading