vxrn 2.12.1 → 2.13.1
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/exports/prebuildWithoutExpo.mjs +2 -46
- package/dist/exports/prebuildWithoutExpo.mjs.map +1 -1
- package/dist/exports/prebuildWithoutExpo.native.js +14 -59
- package/dist/exports/prebuildWithoutExpo.native.js.map +1 -1
- package/dist/utils/nativeSourceContract.mjs +3 -1
- package/dist/utils/nativeSourceContract.mjs.map +1 -1
- package/dist/utils/nativeSourceContract.native.js +5 -2
- package/dist/utils/nativeSourceContract.native.js.map +1 -1
- package/package.json +13 -13
- package/src/exports/prebuildWithoutExpo.ts +2 -48
- package/src/utils/nativeSourceContract.ts +4 -3
- package/types/exports/prebuildWithoutExpo.d.ts.map +1 -1
- package/types/utils/nativeSourceContract.d.ts.map +1 -1
|
@@ -1499,15 +1499,18 @@ function nativeSourceContract(file, source) {
|
|
|
1499
1499
|
i = end + 1;
|
|
1500
1500
|
previous = i;
|
|
1501
1501
|
};
|
|
1502
|
+
var _packageLine_at;
|
|
1502
1503
|
var language = file.endsWith(".swift") ? "swift" : file.endsWith(".kt") ? "kotlin" : void 0;
|
|
1503
1504
|
if (!language) throw new Error(`${file}: expected a .swift or .kt source file`);
|
|
1504
1505
|
var list = tokens(file, source);
|
|
1505
1506
|
var packageToken = language === "kotlin" ? list.findIndex(function(token) {
|
|
1506
1507
|
return token.text === "package";
|
|
1507
1508
|
}) : -1;
|
|
1508
|
-
var
|
|
1509
|
+
var packageLine = packageToken < 0 ? [] : list.slice(packageToken + 1).filter(function(token) {
|
|
1509
1510
|
return token.line === list[packageToken].line;
|
|
1510
|
-
})
|
|
1511
|
+
});
|
|
1512
|
+
while (((_packageLine_at = packageLine.at(-1)) === null || _packageLine_at === void 0 ? void 0 : _packageLine_at.text) === ";") packageLine.pop();
|
|
1513
|
+
var packageName = packageToken < 0 ? void 0 : packageLine.map(function(token) {
|
|
1511
1514
|
return token.text;
|
|
1512
1515
|
}).join("");
|
|
1513
1516
|
if (packageName && !/^[A-Za-z_][A-Za-z0-9_]*(\.[A-Za-z_][A-Za-z0-9_]*)*$/.test(packageName)) {
|