@marko/language-tools
Advanced tools
@@ -1,4 +0,4 @@ | ||
| import { Parsed } from "../../parser"; | ||
| import { type Parsed } from "../../parser"; | ||
| export declare function extractHTML(parsed: Parsed): { | ||
| extracted: import("../../util/extractor").Extracted; | ||
| extracted: import("../..").Extracted; | ||
| nodeDetails: { | ||
@@ -5,0 +5,0 @@ [id: string]: { |
@@ -20,2 +20,2 @@ import type { TaglibLookup } from "@marko/compiler/babel-utils"; | ||
| } | ||
| export declare function extractScript(opts: ExtractScriptOptions): import("../../util/extractor").Extracted; | ||
| export declare function extractScript(opts: ExtractScriptOptions): import("../..").Extracted; |
@@ -1,2 +0,2 @@ | ||
| import { type Node, Parsed, type Range, Repeatable, Repeated } from "../../../parser"; | ||
| import { type Node, type Parsed, type Range, type Repeatable, type Repeated } from "../../../parser"; | ||
| import { ScriptParser } from "./script-parser"; | ||
@@ -3,0 +3,0 @@ export type Scope = ProgramScope | TagScope; |
| import type { TaglibLookup } from "@marko/compiler/babel-utils"; | ||
| import { Parsed } from "../../../parser"; | ||
| import { type Parsed } from "../../../parser"; | ||
| export type RuntimeAPI = (typeof RuntimeAPI)[keyof typeof RuntimeAPI]; | ||
@@ -4,0 +4,0 @@ export declare const RuntimeAPI: { |
@@ -1,2 +0,2 @@ | ||
| import { type Node, Repeated } from "../../../parser"; | ||
| import { type Node, type Repeated } from "../../../parser"; | ||
| export declare function isTextOnlyScript(tag: Node.ParentTag): tag is Node.Tag & { | ||
@@ -3,0 +3,0 @@ nameText: "script"; |
@@ -1,2 +0,2 @@ | ||
| import { Node } from "../parser"; | ||
| import { type Node } from "../parser"; | ||
| export declare function getNodeAtOffset(offset: number, program: Node.Program): Node.AnyNode; |
+16
-16
@@ -442,20 +442,20 @@ // This is a typescript file which defines utilities used in the output of the typescript extractor. | ||
| // TODO: this could be improved. | ||
| // currently falls back to DefaultRenderer too eagerly. | ||
| export type DynamicRenderer<Name> = [0] extends [1 & Name] | ||
| ? DefaultRenderer | ||
| : [Name] extends [Marko.Template<any, any>] | ||
| ? TemplateRenderer<Name> | ||
| : [Name] extends [string] | ||
| ? NativeTagRenderer<Name> | ||
| : [Name] extends [AnyMarkoBody] | ||
| ? BodyRenderer<Name> | ||
| : [Name] extends [ | ||
| { | ||
| [BodyContentKey in DefaultBodyContentKey]?: infer BodyValue extends | ||
| AnyMarkoBody; | ||
| }, | ||
| ] | ||
| ? BodyRenderer<BodyValue> | ||
| : DefaultRenderer; | ||
| : [Name] extends [Marko.Template<any, any> | string] | ||
| ? { | ||
| (): () => <Input extends Marko.Input<Name>>( | ||
| input: Marko.Directives & Input, | ||
| ) => ReturnAndScope<Scopes<Input>, Marko.Return<Name>>; | ||
| } | ||
| : [Name] extends [AnyMarkoBody] | ||
| ? BodyRenderer<Name> | ||
| : [Name] extends [ | ||
| { | ||
| [BodyContentKey in DefaultBodyContentKey]?: infer BodyValue extends | ||
| AnyMarkoBody; | ||
| }, | ||
| ] | ||
| ? BodyRenderer<BodyValue> | ||
| : DefaultRenderer; | ||
@@ -462,0 +462,0 @@ export type TemplateRenderer<Template> = Template extends { |
+30
-30
| { | ||
| "name": "@marko/language-tools", | ||
| "version": "2.5.59", | ||
| "description": "Marko Language Tools", | ||
| "version": "2.5.58", | ||
| "bugs": "https://github.com/marko-js/language-server/issues/new?template=Bug_report.md", | ||
| "dependencies": { | ||
| "@marko/compiler": "^5.39.61", | ||
| "@luxass/strip-json-comments": "^1.4.0", | ||
| "htmljs-parser": "^5.10.2", | ||
| "relative-import-path": "^1.0.0" | ||
| "keywords": [ | ||
| "analysis", | ||
| "analyze", | ||
| "language", | ||
| "marko", | ||
| "tools" | ||
| ], | ||
| "homepage": "https://github.com/marko-js/language-server/tree/main/packages/language-tools/README.md", | ||
| "bugs": "https://github.com/marko-js/language-server/issues/new?template=bug-report.yml", | ||
| "repository": { | ||
| "type": "git", | ||
| "url": "https://github.com/marko-js/language-server/tree/main/packages/language-tools" | ||
| }, | ||
| "devDependencies": { | ||
| "@types/babel__code-frame": "^7.27.0", | ||
| "@typescript/vfs": "^1.6.4", | ||
| "marko": "^5.38.31", | ||
| "mitata": "^1.0.34", | ||
| "tsx": "^4.21.0" | ||
| }, | ||
| "license": "MIT", | ||
| "exports": { | ||
@@ -26,2 +26,4 @@ ".": { | ||
| }, | ||
| "main": "./dist/index.js", | ||
| "module": "./dist/index.mjs", | ||
| "files": [ | ||
@@ -33,21 +35,19 @@ "dist", | ||
| ], | ||
| "homepage": "https://github.com/marko-js/language-server/tree/main/packages/language-tools/README.md", | ||
| "keywords": [ | ||
| "analysis", | ||
| "analyze", | ||
| "language", | ||
| "marko", | ||
| "tools" | ||
| ], | ||
| "license": "MIT", | ||
| "main": "./dist/index.js", | ||
| "module": "./dist/index.mjs", | ||
| "repository": { | ||
| "type": "git", | ||
| "url": "https://github.com/marko-js/language-server/tree/main/packages/language-tools" | ||
| }, | ||
| "scripts": { | ||
| "bench": "BENCH=1 mocha './src/**/__tests__/*.test.ts'", | ||
| "build": "tsc -b && tsx build.mts" | ||
| "build": "tsx build.mts" | ||
| }, | ||
| "dependencies": { | ||
| "@luxass/strip-json-comments": "^1.4.0", | ||
| "@marko/compiler": "^5.39.63", | ||
| "htmljs-parser": "^5.10.2", | ||
| "relative-import-path": "^1.0.0" | ||
| }, | ||
| "devDependencies": { | ||
| "@types/babel__code-frame": "^7.27.0", | ||
| "@typescript/vfs": "^1.6.4", | ||
| "marko": "^5.38.36", | ||
| "mitata": "^1.0.34", | ||
| "tsx": "^4.21.0" | ||
| } | ||
| } |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
314086
0.06%9530
0.06%Updated