Skip to content

Commit 6fa5a40

Browse files
authored
fix(javascript): algoliaseach bundling (#2185)
1 parent 71cdaa1 commit 6fa5a40

File tree

7 files changed

+15
-13
lines changed

7 files changed

+15
-13
lines changed

.github/.cache_version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.0.98
1+
0.0.99

Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ ENV DOCKER=true
1414
# use bash for subsequent commands
1515
SHELL ["/bin/bash", "--login", "-c"]
1616

17-
# Global
17+
# Global (python3 is needed by npm to build parcel on some platforms)
1818
RUN apt-get update && apt-get install -y --no-install-recommends \
19-
curl zip unzip git openssh-server \
19+
curl zip unzip git openssh-server python3 \
2020
&& apt-get clean \
2121
&& rm -rf /var/lib/apt/lists/*
2222

clients/algoliasearch-client-javascript/bundlesize.config.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"files": [
33
{
44
"path": "packages/algoliasearch/dist/algoliasearch.umd.js",
5-
"maxSize": "8.55KB"
5+
"maxSize": "8.10KB"
66
},
77
{
88
"path": "packages/algoliasearch/dist/lite/lite.umd.js",
@@ -34,7 +34,7 @@
3434
},
3535
{
3636
"path": "packages/ingestion/dist/ingestion.umd.js",
37-
"maxSize": "4.95KB"
37+
"maxSize": "5.05KB"
3838
},
3939
{
4040
"path": "packages/monitoring/dist/monitoring.umd.js",

playground/javascript/node/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
"name": "javascript-playground",
33
"version": "0.0.0",
44
"private": true,
5+
"type": "module",
56
"scripts": {
67
"start:algoliasearch": "ts-node algoliasearch.ts",
78
"start:abtesting": "ts-node abtesting.ts",
Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,14 @@
11
{
22
"extends": "../../../config/base.tsconfig.json",
33
"compilerOptions": {
4+
"module": "esnext",
5+
"target": "esnext",
46
"outDir": "dist"
57
},
6-
"include": ["*.ts"]
8+
"ts-node": {
9+
"esm": true
10+
},
11+
"include": [
12+
"*.ts"
13+
]
714
}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
// eslint-disable-next-line import/no-unresolved
2-
export * from './dist/builds/node';
2+
export * from './dist/{{#isAlgoliasearchClient}}algoliasearch/{{/isAlgoliasearchClient}}builds/node';

templates/javascript/clients/tsconfig.mustache

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,6 @@
66
{{/isAlgoliasearchClient}}
77
"outDir": "dist"
88
},
9-
{{#isAlgoliasearchClient}}
10-
"include": ["*.ts"],
11-
"exclude": ["dist", "node_modules", "__tests__", "lite"]
12-
{{/isAlgoliasearchClient}}
13-
{{^isAlgoliasearchClient}}
149
"include": ["{{apiPackage}}", "model", "builds"],
1510
"exclude": ["dist", "node_modules"]
16-
{{/isAlgoliasearchClient}}
1711
}

0 commit comments

Comments
 (0)