@lokascript/vite-plugin 1.1.2 → 1.1.3
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.
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1618,7 +1618,7 @@ function getSemanticExports(config) {
|
|
|
1618
1618
|
|
|
1619
1619
|
// src/generator.ts
|
|
1620
1620
|
function stripTypes(code) {
|
|
1621
|
-
return code.replace(/\s+as\s+\w+<[^>]*(?:<[^>]*>[^>]*)*>/g, "").replace(/\s+as\s+\w+(?:\[\])?/g, "").replace(/:\s*\w+<[^>]*(?:<[^>]*>[^>]*)*>(?=\s*[=;,)\]])/g, "").replace(
|
|
1621
|
+
return code.replace(/\s+as\s+\w+<[^>]*(?:<[^>]*>[^>]*)*>/g, "").replace(/\s+as\s+\w+(?:\[\])?/g, "").replace(/:\s*\w+<[^>]*(?:<[^>]*>[^>]*)*>(?:\[\])?(?=\s*[=;,)\]])/g, "").replace(
|
|
1622
1622
|
/:\s*(?:string|number|boolean|any|unknown|void|never|null|undefined|object|symbol|bigint)(?=\s*[=;,)\]])/g,
|
|
1623
1623
|
""
|
|
1624
1624
|
).replace(/:\s*[A-Z]\w*(?:\[\])?(?=\s*[=;,)\]])/g, "").replace(/\((\w+):\s*(?:\w+|unknown|any)\)/g, "($1)").replace(/Promise<[^>]+>/g, "Promise").replace(/Array<[^>]+>/g, "Array").replace(/\):\s*\w+(?:<[^>]*>)?(?:\[\])?\s*(?=[{=])/g, ") ").replace(/\):\s*\w+(?:<[^>]*>)?\s*=>/g, ") =>").replace(
|