We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
AcornJsxParser
1 parent f5c107b commit 41f88a4Copy full SHA for 41f88a4
index.d.ts
@@ -1,12 +1,19 @@
1
-import { Parser } from 'acorn'
+import acorn from 'acorn';
2
3
-declare const jsx: (options?: jsx.Options) => (BaseParser: typeof Parser) => typeof Parser;
+export const jsx: (options?: jsx.Options) => (BaseParser: typeof acorn.Parser) => typeof acorn.Parser;
4
5
-declare namespace jsx {
6
- interface Options {
7
- allowNamespacedObjects?: boolean;
8
- allowNamespaces?: boolean;
9
- }
+export interface Options {
+ allowNamespacedObjects?: boolean;
+ allowNamespaces?: boolean;
10
}
11
12
-export = jsx;
+export class AcornJsxParser extends acorn.Parser {
+ static readonly acornJsx: {
+ tokTypes: typeof acorn.tokTypes
13
+ };
14
+
15
+ jsx_readString(quote: number): void;
16
+}
17
18
+export as namespace jsx;
19
+export default jsx;
0 commit comments