Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@markuplint/ml-ast

Package Overview
Dependencies
Maintainers
1
Versions
120
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@markuplint/ml-ast - npm Package Compare versions

Comparing version 3.0.0-alpha.0 to 3.0.0-alpha.1

43

lib/types.d.ts

@@ -14,3 +14,3 @@ export interface MLToken {

export declare type MLASTNode = MLASTDoctype | MLASTTag | MLASTComment | MLASTText | MLASTPreprocessorSpecificBlock | MLASTAttr;
export interface MLASTAbstructNode extends MLToken {
export interface MLASTAbstractNode extends MLToken {
type: MLASTNodeType;

@@ -24,3 +24,3 @@ nodeName: string;

}
export interface MLASTDoctype extends MLASTAbstructNode {
export interface MLASTDoctype extends MLASTAbstractNode {
type: 'doctype';

@@ -31,5 +31,6 @@ name: string;

}
export interface MLASTElement extends MLASTAbstructNode {
export interface MLASTElement extends MLASTAbstractNode {
type: 'starttag';
namespace: string;
elementType: ElementType;
attributes: MLASTAttr[];

@@ -43,5 +44,12 @@ hasSpreadAttr: boolean;

tagCloseChar: string;
isCustomElement: boolean;
}
export interface MLASTElementCloseTag extends MLASTAbstructNode {
/**
* Element type
*
* - `html`: From native HTML Standard
* - `web-component`: As the Web Component according to HTML Standard
* - `authored`: Authored element (JSX Element etc.) through the view framework or the template engine.
*/
export declare type ElementType = 'html' | 'web-component' | 'authored';
export interface MLASTElementCloseTag extends MLASTAbstractNode {
type: 'endtag';

@@ -54,5 +62,4 @@ namespace: string;

tagCloseChar: string;
isCustomElement: boolean;
}
export interface MLASTPreprocessorSpecificBlock extends MLASTAbstructNode {
export interface MLASTPreprocessorSpecificBlock extends MLASTAbstractNode {
type: 'psblock';

@@ -68,10 +75,10 @@ nodeName: string;

export declare type MLASTParentNode = MLASTElement | MLASTPreprocessorSpecificBlock;
export interface MLASTComment extends MLASTAbstructNode {
export interface MLASTComment extends MLASTAbstractNode {
type: 'comment';
}
export interface MLASTText extends MLASTAbstructNode {
export interface MLASTText extends MLASTAbstractNode {
type: 'text';
}
export declare type MLASTAttr = MLASTHTMLAttr | MLASTPreprocessorSpecificAttr;
export interface MLASTHTMLAttr extends MLASTAbstructNode {
export interface MLASTHTMLAttr extends MLASTAbstractNode {
type: 'html-attr';

@@ -97,3 +104,3 @@ spacesBeforeName: MLToken;

}
export interface MLASTPreprocessorSpecificAttr extends MLASTAbstructNode {
export interface MLASTPreprocessorSpecificAttr extends MLASTAbstractNode {
type: 'ps-attr';

@@ -108,6 +115,10 @@ potentialName: string;

isFragment: boolean;
unkownParseError?: string;
unknownParseError?: string;
}
export interface MLMarkupLanguageParser {
parse(sourceCode: string, offsetOffset?: number, offsetLine?: number, offsetColumn?: number, ignoreFrontMatter?: boolean): MLASTDocument;
parse(sourceCode: string, options?: ParserOptions & {
offsetOffset?: number;
offsetLine?: number;
offsetColumn?: number;
}): MLASTDocument;
/**

@@ -118,2 +129,8 @@ * @default "omittable"

}
export declare type ParserOptions = {
ignoreFrontMatter?: boolean;
authoredElementName?: ParserAuthoredElementNameDistinguishing;
};
export declare type ParserAuthoredElementNameDistinguishing = string | RegExp | ParserAuthoredElementNameDistinguishingFunction | (string | RegExp | ParserAuthoredElementNameDistinguishingFunction)[];
export declare type ParserAuthoredElementNameDistinguishingFunction = (name: string) => boolean;
export declare type Parse = MLMarkupLanguageParser['parse'];

@@ -120,0 +137,0 @@ export declare type Walker = (node: MLASTNode, depth: number) => void;

{
"name": "@markuplint/ml-ast",
"version": "3.0.0-alpha.0",
"version": "3.0.0-alpha.1",
"description": "The markuplint AST types.",

@@ -18,3 +18,3 @@ "repository": "git@github.com:markuplint/markuplint.git",

},
"gitHead": "d32c522e016888e20bcbb5f09352c006b964f193"
"gitHead": "56de89456146a06777eb5b6d4e8ba456147dd18b"
}

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc