sommark 3.0.0 → 3.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +6 -0
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -286,6 +286,10 @@ async function transpile(options = {}) {
286
286
  return await sm.transpile();
287
287
  }
288
288
 
289
+ const lexSync = src => lexer(src);
290
+
291
+ const parseSync = src => parser(lexer(src));
292
+
289
293
  export {
290
294
  HTML,
291
295
  MARKDOWN,
@@ -298,6 +302,8 @@ export {
298
302
  lex,
299
303
  parse,
300
304
  transpile,
305
+ lexSync,
306
+ parseSync,
301
307
  TOKEN_TYPES,
302
308
  labels,
303
309
  enableColor,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sommark",
3
- "version": "3.0.0",
3
+ "version": "3.1.0",
4
4
  "description": "SomMark is a declarative, extensible markup language for structured content that can be converted to HTML, Markdown, MDX, JSON, and more.",
5
5
  "main": "index.js",
6
6
  "directories": {