@embeddable.com/sdk-core 3.5.1 → 3.5.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@embeddable.com/sdk-core",
3
- "version": "3.5.1",
3
+ "version": "3.5.2",
4
4
  "description": "Core Embeddable SDK module responsible for web-components bundling and publishing.",
5
5
  "keywords": [
6
6
  "embeddable",
package/src/dev.ts CHANGED
@@ -23,6 +23,7 @@ import { findFiles } from "@embeddable.com/sdk-utils";
23
23
  import { archive, YAML_OR_JS_FILES, sendBuild } from "./push";
24
24
  import validate from "./validate";
25
25
  import { checkNodeVersion } from "./utils";
26
+ import { createManifest } from "./cleanup";
26
27
  const minimist = require("minimist");
27
28
 
28
29
  const oraP = import("ora");
@@ -68,10 +69,7 @@ export default async () => {
68
69
 
69
70
  const defaultConfig = await provideConfig();
70
71
 
71
- const buildDir = path.resolve(
72
- defaultConfig.client.rootDir,
73
- ".embeddable-dev-build",
74
- );
72
+ const buildDir = path.resolve(defaultConfig.client.rootDir, BUILD_DEV_DIR);
75
73
 
76
74
  const config = {
77
75
  ...defaultConfig,
@@ -82,7 +80,7 @@ export default async () => {
82
80
  },
83
81
  client: {
84
82
  ...defaultConfig.client,
85
- buildDir: buildDir,
83
+ buildDir,
86
84
  componentDir: path.resolve(buildDir, "component"),
87
85
  stencilBuild: path.resolve(buildDir, "dist", "embeddable-wrapper"),
88
86
  tmpDir: path.resolve(defaultConfig.client.rootDir, ".embeddable-dev-tmp"),
@@ -140,6 +138,20 @@ export default async () => {
140
138
  );
141
139
  }
142
140
 
141
+ await createManifest({
142
+ ctx: {
143
+ ...config,
144
+ client: {
145
+ ...config.client,
146
+ tmpDir: buildDir,
147
+ },
148
+ },
149
+ typesFileName: "embeddable-types.js",
150
+ stencilWrapperFileName: "embeddable-wrapper.js",
151
+ metaFileName: "embeddable-components-meta.js",
152
+ editorsMetaFileName: "embeddable-editors-meta.js",
153
+ });
154
+
143
155
  await sendDataModelsAndSecurityContextsChanges(config);
144
156
 
145
157
  for (const getPlugin of config.plugins) {
@@ -234,6 +246,13 @@ const sendDataModelsAndSecurityContextsChanges = async (ctx: any) => {
234
246
  "Synchronising data models and/or security contexts...",
235
247
  ).start();
236
248
  const filesList = await findFiles(ctx.client.modelsSrc, YAML_OR_JS_FILES);
249
+
250
+ // add manifest to the archive
251
+ filesList.push([
252
+ "embeddable-manifest",
253
+ path.resolve(ctx.client.buildDir, "embeddable-manifest.json"),
254
+ ]);
255
+
237
256
  await archive(ctx, filesList, false);
238
257
  await sendBuild(ctx, { workspaceId: previewWorkspace, token });
239
258
  sending.succeed(`Data models and/or security context synchronized`);