Skip to main content
Module

x/scaffold/src/deps/types.ts>KebabCasedProperties

scaffold your next project with style and 💗
Latest
type alias KebabCasedProperties
import { type KebabCasedProperties } from "https://deno.land/x/scaffold@0.3.0/src/deps/types.ts";

Convert object properties to kebab case but not recursively.

This can be useful when, for example, converting some API types from a different style.

Examples

Example 1

import type {KebabCasedProperties} from 'type-fest';

interface User {
	userId: number;
	userName: string;
}

const result: KebabCasedProperties<User> = {
	'user-id': 1,
	'user-name': 'Tom',
};