sveltedoc-parser
Advanced tools
Comparing version 2.3.0 to 2.3.1
@@ -6,2 +6,6 @@ # Change Log | ||
## [2.3.1] 25.11.2019 | ||
- [Fixed] Svelte V3: Fix parsing issues when anonymous functions are used in event handlers at markup (Issue #18) | ||
## [2.3.0] 02.10.2019 | ||
@@ -8,0 +12,0 @@ |
@@ -461,2 +461,8 @@ const EventEmitter = require('events'); | ||
parseMarkupExpressionBlock(expression, offset) { | ||
// Add name for anonymous functions to prevent parser error | ||
const regex = /^{\s*function\s+\(/i; | ||
expression = expression.replace(regex, function() { | ||
return "{function a("; | ||
}); | ||
const ast = espree.parse( | ||
@@ -463,0 +469,0 @@ expression, |
{ | ||
"name": "sveltedoc-parser", | ||
"version": "2.3.0", | ||
"version": "2.3.1", | ||
"description": "Generate a JSON documentation for a Svelte file", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -14,2 +14,6 @@ # The sveltedoc parser | ||
### [2.3.1] 25.11.2019 | ||
- [Fixed] Svelte V3: Fix parsing issues when anonymous functions are used in event handlers at markup (Issue #18) | ||
Full changelog of release versions can be found [here](/CHANGELOG.md) | ||
@@ -16,0 +20,0 @@ |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
117874
2255
140