You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/parse.js
+12-3Lines changed: 12 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -1,10 +1,19 @@
1
-
import{Document}from"postcss";
2
-
import{Input}from"postcss";
1
+
import{Document,Input}from"postcss";
3
2
import{AngularParser}from"./parser-angular.js";
4
3
5
4
/**
6
-
* Parses Angular code and returns a Document.
5
+
* Represents an object that can be converted to a string.
7
6
*
7
+
* @typedef {object} Stringifiable
8
+
* @property {function(): string} toString - Method to convert the object to a string.
9
+
*/
10
+
11
+
/**
12
+
* Parses Angular code and generates a PostCSS Document representing the Abstract Syntax Tree (AST).
13
+
*
14
+
* @param {string | Stringifiable} angularCode - The Angular source code to be parsed, provided either as a string or as an object implementing the toString() method.
15
+
* @param {import('postcss').ProcessOptions} opts - The PostCSS processing options.
16
+
* @returns {Document} A PostCSS Document object representing the parsed AST.
0 commit comments