Skip to content
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
5 changes: 5 additions & 0 deletions .changeset/fix-create-deprecation-scope.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'sv': patch
---

fix(sv): scope `@deprecated` tag to the legacy `create(cwd, options)` overload only
2 changes: 1 addition & 1 deletion packages/sv/api-surface.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ type FileType = {
condition?: ConditionDefinition;
content: (editor: FileEditor) => string;
};
declare function create(options: Options): void;
/** @deprecated use `create({ cwd, ...options })` instead. */
declare function create(cwd: string, options: Omit<Options, 'cwd'>): void;
declare function create(options: Options): void;
export {
type Addon,
type AddonDefinition,
Expand Down
2 changes: 1 addition & 1 deletion packages/sv/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ import { create as _create, type Options as CreateOptions } from './create/index

export type { TemplateType, LanguageType } from './create/index.ts';

export function create(options: CreateOptions): void;
/** @deprecated use `create({ cwd, ...options })` instead. */
export function create(cwd: string, options: Omit<CreateOptions, 'cwd'>): void;
export function create(options: CreateOptions): void;
export function create(
cwdOrOptions: string | CreateOptions,
legacyOptions?: Omit<CreateOptions, 'cwd'>
Expand Down
Loading