diff --git a/api/.swcrc b/api/.swcrc
index 41d8f80f..794efbd7 100644
--- a/api/.swcrc
+++ b/api/.swcrc
@@ -1,13 +1,16 @@
{
+ "module": {
+ "type": "commonjs"
+ },
"jsc": {
"parser": {
"syntax": "typescript",
"decorators": true
},
"target": "es2021",
- "baseUrl": ".",
+ "baseUrl": "./",
"paths": {
- "@fosscord/api": ["src/index"],
+ "@fosscord/api": ["src/index.ts"],
"@fosscord/api/*": ["src/*"]
}
}
diff --git a/bundle/.swcrc b/bundle/.swcrc
index bdcea43b..9a89b49d 100644
--- a/bundle/.swcrc
+++ b/bundle/.swcrc
@@ -1,22 +1,12 @@
{
+ "module": {
+ "type": "commonjs"
+ },
"jsc": {
"parser": {
- "syntax": "ecmascript",
- "jsx": false,
- "dynamicImport": false,
- "privateMethod": false,
- "functionBind": false,
- "exportDefaultFrom": false,
- "exportNamespaceFrom": false,
- "decorators": false,
- "decoratorsBeforeExport": false,
- "topLevelAwait": false,
- "importMeta": false
+ "syntax": "typescript",
+ "decorators": true
},
- "transform": null,
- "target": "es2021",
- "loose": false,
- "externalHelpers": false,
- "keepClassNames": false
+ "target": "es2021"
}
}
diff --git a/cdn/.swcrc b/cdn/.swcrc
index 8e753640..ab531194 100644
--- a/cdn/.swcrc
+++ b/cdn/.swcrc
@@ -1,4 +1,7 @@
{
+ "module": {
+ "type": "commonjs"
+ },
"jsc": {
"parser": {
"syntax": "typescript",
diff --git a/gateway/.swcrc b/gateway/.swcrc
index 0cf5e465..3079a89f 100644
--- a/gateway/.swcrc
+++ b/gateway/.swcrc
@@ -1,4 +1,7 @@
{
+ "module": {
+ "type": "commonjs"
+ },
"jsc": {
"parser": {
"syntax": "typescript",
diff --git a/rtc/.swcrc b/rtc/.swcrc
deleted file mode 100644
index f04801b8..00000000
--- a/rtc/.swcrc
+++ /dev/null
@@ -1,9 +0,0 @@
-{
- "jsc": {
- "parser": {
- "syntax": "typescript",
- "decorators": true
- },
- "target": "es2021"
- }
-}
\ No newline at end of file
diff --git a/util/.swcrc b/util/.swcrc
index f04801b8..a723d37f 100644
--- a/util/.swcrc
+++ b/util/.swcrc
@@ -1,9 +1,18 @@
{
- "jsc": {
- "parser": {
- "syntax": "typescript",
- "decorators": true
- },
- "target": "es2021"
- }
-}
\ No newline at end of file
+ "module": {
+ "type": "commonjs"
+ },
+ "jsc": {
+ "parser": {
+ "syntax": "typescript",
+ "decorators": true
+ },
+ "target": "es2021",
+ "transform": {
+ "legacyDecorator": true,
+ "decoratorMetadata": true
+ },
+ "keepClassNames": true,
+ "loose": true
+ }
+}
diff --git a/webrtc/.swcrc b/webrtc/.swcrc
index f04801b8..9a89b49d 100644
--- a/webrtc/.swcrc
+++ b/webrtc/.swcrc
@@ -1,9 +1,12 @@
{
- "jsc": {
- "parser": {
- "syntax": "typescript",
- "decorators": true
- },
- "target": "es2021"
- }
-}
\ No newline at end of file
+ "module": {
+ "type": "commonjs"
+ },
+ "jsc": {
+ "parser": {
+ "syntax": "typescript",
+ "decorators": true
+ },
+ "target": "es2021"
+ }
+}
|