@wix/site-service-configuration 1.0.1 → 1.0.2
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/cjs/build/definition/index.js.map +1 -1
- package/cjs/build/implementations/configurationService.js.map +1 -1
- package/cjs/package.json +1 -1
- package/definition/package.json +1 -1
- package/dist/definition/index.js.map +1 -1
- package/dist/implementations/configurationService.js.map +1 -1
- package/implementations/package.json +1 -1
- package/package.json +16 -16
- package/src/definition/index.ts +7 -7
- package/src/implementations/configurationService.ts +17 -17
- package/types/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/definition/index.ts"],"names":[],"mappings":";;;AAAA,oEAAyD;AAiB5C,QAAA,uBAAuB,GAAG,IAAA,oCAAa,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/definition/index.ts"],"names":[],"mappings":";;;AAAA,oEAAyD;AAiB5C,QAAA,uBAAuB,GAAG,IAAA,oCAAa,EACnD,iCAAiC,CACjC,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"configurationService.js","sourceRoot":"","sources":["../../../src/implementations/configurationService.ts"],"names":[],"mappings":";;;AAAA,oEAA4D;AAG5D,8CAAuD;AAE1C,QAAA,oBAAoB,GAAG,IAAA,uCAAgB,
|
|
1
|
+
{"version":3,"file":"configurationService.js","sourceRoot":"","sources":["../../../src/implementations/configurationService.ts"],"names":[],"mappings":";;;AAAA,oEAA4D;AAG5D,8CAAuD;AAE1C,QAAA,oBAAoB,GAAG,IAAA,uCAAgB,EACnD,oCAAuB,EACvB,CAAC,EAAE,MAAM,EAAmD,EAAyB,EAAE;IACtF,MAAM,MAAM,GAAG,MAAM,CAAC,MAAM,IAAI,KAAK,CAAA;IACrC,MAAM,oBAAoB,GAAG,MAAM,CAAC,oBAAoB,IAAI,KAAK,CAAA;IACjE,MAAM,iBAAiB,GAAG,MAAM,CAAC,iBAAiB,IAAI,KAAK,CAAA;IAE3D,OAAO;QACN,IAAI,MAAM;YACT,OAAO,MAAM,CAAA;QACd,CAAC;QACD,IAAI,oBAAoB;YACvB,OAAO,oBAAoB,CAAA;QAC5B,CAAC;QACD,IAAI,iBAAiB;YACpB,OAAO,iBAAiB,CAAA;QACzB,CAAC;KACD,CAAA;AACF,CAAC,CACD,CAAA"}
|
package/cjs/package.json
CHANGED
package/definition/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/definition/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAA;AAiBzD,MAAM,CAAC,MAAM,uBAAuB,GAAG,aAAa,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/definition/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAA;AAiBzD,MAAM,CAAC,MAAM,uBAAuB,GAAG,aAAa,CACnD,iCAAiC,CACjC,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"configurationService.js","sourceRoot":"","sources":["../../src/implementations/configurationService.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAA;AAG5D,OAAO,EAAE,uBAAuB,EAAE,MAAM,eAAe,CAAA;AAEvD,MAAM,CAAC,MAAM,oBAAoB,GAAG,gBAAgB,
|
|
1
|
+
{"version":3,"file":"configurationService.js","sourceRoot":"","sources":["../../src/implementations/configurationService.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAA;AAG5D,OAAO,EAAE,uBAAuB,EAAE,MAAM,eAAe,CAAA;AAEvD,MAAM,CAAC,MAAM,oBAAoB,GAAG,gBAAgB,CACnD,uBAAuB,EACvB,CAAC,EAAE,MAAM,EAAmD,EAAyB,EAAE;IACtF,MAAM,MAAM,GAAG,MAAM,CAAC,MAAM,IAAI,KAAK,CAAA;IACrC,MAAM,oBAAoB,GAAG,MAAM,CAAC,oBAAoB,IAAI,KAAK,CAAA;IACjE,MAAM,iBAAiB,GAAG,MAAM,CAAC,iBAAiB,IAAI,KAAK,CAAA;IAE3D,OAAO;QACN,IAAI,MAAM;YACT,OAAO,MAAM,CAAA;QACd,CAAC;QACD,IAAI,oBAAoB;YACvB,OAAO,oBAAoB,CAAA;QAC5B,CAAC;QACD,IAAI,iBAAiB;YACpB,OAAO,iBAAiB,CAAA;QACzB,CAAC;KACD,CAAA;AACF,CAAC,CACD,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/site-service-configuration",
|
|
3
|
-
"version": "1.0.
|
|
4
|
-
"main": "cjs/build/index.js",
|
|
5
|
-
"module": "dist/index.js",
|
|
6
|
-
"types": "dist/index.d.ts",
|
|
3
|
+
"version": "1.0.2",
|
|
7
4
|
"license": "UNLICENSED",
|
|
8
5
|
"files": [
|
|
9
6
|
"dist",
|
|
@@ -15,6 +12,10 @@
|
|
|
15
12
|
"!**/*.tsbuildinfo",
|
|
16
13
|
"!doc.md"
|
|
17
14
|
],
|
|
15
|
+
"sideEffects": false,
|
|
16
|
+
"main": "cjs/build/index.js",
|
|
17
|
+
"module": "dist/index.js",
|
|
18
|
+
"types": "dist/index.d.ts",
|
|
18
19
|
"exports": {
|
|
19
20
|
".": {
|
|
20
21
|
"types": "./dist/index.d.ts",
|
|
@@ -42,6 +43,16 @@
|
|
|
42
43
|
"require": "./cjs/build/service.js"
|
|
43
44
|
}
|
|
44
45
|
},
|
|
46
|
+
"publishConfig": {
|
|
47
|
+
"registry": "https://registry.npmjs.org/",
|
|
48
|
+
"access": "public"
|
|
49
|
+
},
|
|
50
|
+
"scripts": {
|
|
51
|
+
"build": "tsc -b . --force && tsc --project tsconfig.cjs.json",
|
|
52
|
+
"lint": "yarn run -T lint:package $npm_package_name",
|
|
53
|
+
"test": "vitest --run && yarn test-type-check",
|
|
54
|
+
"test-type-check": "echo 'validating typescript in test files' && tsc --project tsconfig.test.json && echo 'Finished validating typescript in test files successfully'"
|
|
55
|
+
},
|
|
45
56
|
"dependencies": {
|
|
46
57
|
"@wix/services-definitions": "^0.1.4",
|
|
47
58
|
"@wix/services-manager": "^0.2.20"
|
|
@@ -50,18 +61,7 @@
|
|
|
50
61
|
"typescript": "^5.3.3",
|
|
51
62
|
"vitest": "4.1.0"
|
|
52
63
|
},
|
|
53
|
-
"scripts": {
|
|
54
|
-
"build": "tsc -b . --force && tsc --project tsconfig.cjs.json",
|
|
55
|
-
"lint": "yarn run -T lint:package $npm_package_name",
|
|
56
|
-
"test": "vitest --run && yarn test-type-check",
|
|
57
|
-
"test-type-check": "echo 'validating typescript in test files' && tsc --project tsconfig.test.json && echo 'Finished validating typescript in test files successfully'"
|
|
58
|
-
},
|
|
59
64
|
"publishUnscoped": false,
|
|
60
|
-
"publishConfig": {
|
|
61
|
-
"registry": "https://registry.npmjs.org/",
|
|
62
|
-
"access": "public"
|
|
63
|
-
},
|
|
64
|
-
"sideEffects": false,
|
|
65
65
|
"wix": {
|
|
66
66
|
"artifact": {
|
|
67
67
|
"groupId": "com.wixpress.npm",
|
|
@@ -78,5 +78,5 @@
|
|
|
78
78
|
]
|
|
79
79
|
}
|
|
80
80
|
},
|
|
81
|
-
"falconPackageHash": "
|
|
81
|
+
"falconPackageHash": "a54309d75690377075df500bbed6d97f55d0dfb219d3f7acb93fa44e"
|
|
82
82
|
}
|
package/src/definition/index.ts
CHANGED
|
@@ -2,19 +2,19 @@ import { defineService } from '@wix/services-definitions'
|
|
|
2
2
|
import type { ServiceDefinition } from '@wix/services-definitions'
|
|
3
3
|
|
|
4
4
|
export type IConfigurationServiceConfig = {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
readonly qaMode?: boolean
|
|
6
|
+
readonly trackClicksAnalytics?: boolean
|
|
7
|
+
readonly sandboxInHTMLComp?: boolean
|
|
8
8
|
}
|
|
9
9
|
|
|
10
10
|
export interface IConfigurationService {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
11
|
+
readonly qaMode: boolean
|
|
12
|
+
readonly trackClicksAnalytics: boolean
|
|
13
|
+
readonly sandboxInHTMLComp: boolean
|
|
14
14
|
}
|
|
15
15
|
|
|
16
16
|
export type IConfigurationDefinition = ServiceDefinition<IConfigurationService, IConfigurationServiceConfig>
|
|
17
17
|
|
|
18
18
|
export const ConfigurationDefinition = defineService<IConfigurationService, IConfigurationServiceConfig>(
|
|
19
|
-
|
|
19
|
+
'@wix/site-service-configuration'
|
|
20
20
|
)
|
|
@@ -4,22 +4,22 @@ import type { IConfigurationService, IConfigurationServiceConfig } from '../defi
|
|
|
4
4
|
import { ConfigurationDefinition } from '../definition'
|
|
5
5
|
|
|
6
6
|
export const ConfigurationService = implementService(
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
7
|
+
ConfigurationDefinition,
|
|
8
|
+
({ config }: ServiceFactoryOpts<IConfigurationServiceConfig>): IConfigurationService => {
|
|
9
|
+
const qaMode = config.qaMode ?? false
|
|
10
|
+
const trackClicksAnalytics = config.trackClicksAnalytics ?? false
|
|
11
|
+
const sandboxInHTMLComp = config.sandboxInHTMLComp ?? false
|
|
12
12
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
13
|
+
return {
|
|
14
|
+
get qaMode() {
|
|
15
|
+
return qaMode
|
|
16
|
+
},
|
|
17
|
+
get trackClicksAnalytics() {
|
|
18
|
+
return trackClicksAnalytics
|
|
19
|
+
},
|
|
20
|
+
get sandboxInHTMLComp() {
|
|
21
|
+
return sandboxInHTMLComp
|
|
22
|
+
},
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
25
|
)
|
package/types/package.json
CHANGED