
Product
Introducing Reports: An Extensible Reporting Framework for Socket Data
Explore exportable charts for vulnerabilities, dependencies, and usage with Reports, Socket’s new extensible reporting framework.
@conformyze/yaml-ast-parser
Advanced tools
[](https://travis-ci.org/mulesoft-labs/yaml-ast-parser)
This is a fork of JS-YAML which supports parsing of YAML into AST.
In additional to parsing YAML to AST, it has following features:
!include tag used in RAMLThe type information below is relevant when using TypeScript, if using from JavaScript only the field/method information is relevant.
load method can be used to load the tree and returns a YAMLNode.
YAMLNode class is an ancestor for all node kinds.
It's kind field determine node kind, one of Kind enum:
SCALAR, MAPPING, MAP, SEQ, ANCHOR_REF or INCLUDE_REF.After node kind is determined, it can be cast to one of the YAMLNode descendants types:
YAMLScalar, YAMLMapping, YamlMap, YAMLSequence or YAMLAnchorReference.| class | important members |
|---|---|
YAMLNode | startPosition and endPosition provide node range. |
YAMLScalar | string value field |
YAMLMapping | YAMLScalar key and YAMLNode value fields |
YAMLSequence | YAMLNode[] items field |
YamlMap | YAMLMapping[] mappings field |
YAMLAnchorReference | string referencesAnchor and YAMLNode value |
Scalars are one of the three main node types defined by YAML and are effectively leaf nodes.
There are many factors that can influence the type of datum represent in scalar node (context, schema, tag, etc.).
To help inspection of a YAMLScalar to determine its datatype when a document uses the Core Schema, you can pass the YAMLScalar to the determineScalarType function. It will return an enum value indicating null, bool, int, float, or string.
Once you know the type, there are also some helper functions to help read the value by passing them the string, value: parseYamlBoolean, parseYamlFloat, and parseYamlInteger.
FAQs
[](https://travis-ci.org/mulesoft-labs/yaml-ast-parser)
We found that @conformyze/yaml-ast-parser demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Explore exportable charts for vulnerabilities, dependencies, and usage with Reports, Socket’s new extensible reporting framework.

Product
Socket for Jira lets teams turn alerts into Jira tickets with manual creation, automated ticketing rules, and two-way sync.

Company News
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.