Skip to content

Commit dee995e

Browse files
authored
Add getStaticJSONValue overload type (#8)
1 parent ba53a61 commit dee995e

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/utils/ast.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,9 @@ export function getStaticJSONValue(node: JSONBigIntLiteral): bigint
170170
export function getStaticJSONValue(
171171
node: JSONLiteral,
172172
): string | number | boolean | RegExp | bigint | null
173+
export function getStaticJSONValue(
174+
node: Exclude<JSONExpression, JSONObjectExpression | JSONArrayExpression>,
175+
): Exclude<JSONValue, JSONObjectValue | JSONValue[]>
173176

174177
export function getStaticJSONValue(node: JSONObjectExpression): JSONObjectValue
175178
export function getStaticJSONValue(node: JSONArrayExpression): JSONValue[]

0 commit comments

Comments
 (0)