npm package diff
Package: @forge/bundler
Versions: 4.18.1-next.8-experimental-c7a7d36 - 4.19.0-next.11
Modified:package/out/config/common.js
Index: package/out/config/common.js
===================================================================
--- package/out/config/common.js
+++ package/out/config/common.js
@@ -1,12 +1,13 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
-exports.getCommonWebpackConfig = exports.getDevToolConfig = exports.resolveStubPath = exports.resolveModulePath = exports.getEntryPoints = void 0;
+exports.getCommonWebpackConfig = exports.geti18nRule = exports.getDevToolConfig = exports.resolveStubPath = exports.resolveModulePath = exports.getEntryPoints = void 0;
const tslib_1 = require("tslib");
const path_1 = require("path");
const webpack_1 = tslib_1.__importDefault(require("webpack"));
const text_1 = require("../text");
const cli_shared_1 = require("@forge/cli-shared");
+const i18n_1 = require("@forge/i18n");
const tsconfig_interactor_1 = require("../tsconfig-interactor");
function getEntryPoints(handlers) {
const entryPointMap = new Map();
for (const { module, func } of handlers) {
@@ -37,8 +38,25 @@
}
return config.isDebugMode ? 'inline-source-map' : 'cheap-source-map';
};
exports.getDevToolConfig = getDevToolConfig;
+const geti18nRule = (i18nConfig) => {
+ const i18nResources = i18nConfig.resources || [];
+ const i18nResourcesMap = new Map(i18nResources.map(({ key, path }) => [(0, path_1.resolve)(path), key]));
+ const getFilename = ({ module: { resource: i18nResourcePath } }) => {
+ const i18nResourceKey = i18nResourcesMap.get(i18nResourcePath);
+ return (0, path_1.join)(i18n_1.I18N_BUNDLE_FOLDER_NAME, `${i18nResourceKey}.json`);
+ };
+ return {
+ test: /\.json$/i,
+ include: Array.from(i18nResourcesMap.keys()),
+ type: 'asset/resource',
+ generator: {
+ filename: getFilename
+ }
+ };
+};
+exports.geti18nRule = geti18nRule;
const getCommonWebpackConfig = (entrypoints, config) => {
if (!require.main) {
throw new Error(text_1.Text.noExecutableFile);
}
Modified:package/out/config/nativeui.js
Index: package/out/config/nativeui.js
===================================================================
--- package/out/config/nativeui.js
+++ package/out/config/nativeui.js
@@ -5,9 +5,10 @@
const path_1 = require("path");
const webpack_bundle_analyzer_1 = require("webpack-bundle-analyzer");
const html_webpack_plugin_1 = tslib_1.__importDefault(require("html-webpack-plugin"));
const tmp_1 = tslib_1.__importDefault(require("tmp"));
-const getNativeUiBuildConfig = (entrypoints) => {
+const common_1 = require("./common");
+const getNativeUiBuildConfig = (entrypoints, i18nConfig) => {
const resolvedEntryPoints = {};
for (const entrypoint of entrypoints) {
resolvedEntryPoints[entrypoint.name] = (0, path_1.resolve)(entrypoint.path);
}
@@ -43,8 +44,9 @@
},
target: 'web',
module: {
rules: [
+ ...(i18nConfig ? [(0, common_1.geti18nRule)(i18nConfig)] : []),
{
test: /\.(jpe?g|png|gif|svg)$/i,
type: 'asset/resource'
},
Modified:package/out/webpack.js
Index: package/out/webpack.js
===================================================================
--- package/out/webpack.js
+++ package/out/webpack.js
@@ -190,10 +190,10 @@
const getSandboxBundler = () => createBundler(sandbox_1.getSandboxedRuntimeBuildConfig);
exports.getSandboxBundler = getSandboxBundler;
const getNodeBundler = (wrapperProvider) => createBundler((0, node_1.getNodeRuntimeBuildConfig)(wrapperProvider));
exports.getNodeBundler = getNodeBundler;
-const nativeUiBundle = (logger, entrypoints) => {
- const config = (0, nativeui_1.getNativeUiBuildConfig)(entrypoints);
+const nativeUiBundle = (logger, entrypoints, i18nConfig) => {
+ const config = (0, nativeui_1.getNativeUiBuildConfig)(entrypoints, i18nConfig);
const compiler = (0, exports.getCompiler)(config, { writeToDisk: true });
return new Promise((resolve, reject) => {
compiler.run((compilerError, stats) => {
try {
Modified:package/package.json
Index: package/package.json
===================================================================
--- package/package.json
+++ package/package.json
@@ -1,7 +1,7 @@
{
"name": "@forge/bundler",
- "version": "4.18.1-next.8-experimental-c7a7d36",
+ "version": "4.19.0-next.11",
"description": "Default bundler for Forge apps",
"license": "UNLICENSED",
"author": "Atlassian",
"main": "out/index.js",
@@ -18,12 +18,14 @@
"@babel/plugin-transform-numeric-separator": "^7.23.4",
"@babel/plugin-transform-optional-chaining": "^7.23.4",
"@babel/plugin-transform-react-jsx": "^7.23.4",
"@babel/preset-typescript": "^7.23.3",
- "@forge/api": "3.9.2-next.0-experimental-c7a7d36",
+ "@forge/api": "3.9.2-next.0",
"@forge/babel-plugin-transform-ui": "1.1.18",
- "@forge/cli-shared": "5.5.0-next.8-experimental-c7a7d36",
- "@forge/lint": "5.3.3-next.8-experimental-c7a7d36",
+ "@forge/cli-shared": "5.5.0-next.11",
+ "@forge/i18n": "0.0.1-next.10",
+ "@forge/lint": "5.3.3-next.11",
+ "@forge/manifest": "7.7.0-next.11",
"@forge/util": "1.4.4",
"assert": "^2.1.0",
"babel-loader": "^8.3.0",
"browserify-zlib": "^0.2.0",
Modified:package/out/config/common.d.ts.map
Index: package/out/config/common.d.ts.map
===================================================================
--- package/out/config/common.d.ts.map
+++ package/out/config/common.d.ts.map
@@ -1,1 +1,1 @@
-{"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../../src/config/common.ts"],"names":[],"mappings":"AACA,OAAgB,EAAE,aAAa,IAAI,aAAa,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAEjF,OAAO,EAAE,OAAO,EAAoB,MAAM,mBAAmB,CAAC;AAG9D,MAAM,WAAW,aAAa;IAC5B,WAAW,EAAE,OAAO,CAAC;IACrB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,YAAY,EAAE,MAAM,CAAC;CACtB;AAED,oBAAY,UAAU,GAAG;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;AAEF,oBAAY,mBAAmB,GAAG,UAAU,GAAG;IAC7C,SAAS,EAAE,MAAM,EAAE,CAAC;CACrB,CAAC;AAEF,wBAAgB,cAAc,CAAC,QAAQ,EAAE,OAAO,EAAE,GAAG,mBAAmB,EAAE,CAiBzE;AAED,eAAO,MAAM,iBAAiB,eAAgB,MAAM,KAAG,MAEtD,CAAC;AAEF,wBAAgB,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CA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B,EAAE,CAiBzE;AAED,eAAO,MAAM,iBAAiB,eAAgB,MAAM,KAAG,MAEtD,CAAC;AAEF,wBAAgB,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAExD;AAED,eAAO,MAAM,gBAAgB,WAAY,aAAa,KAAG,MASxD,CAAC;AAEF,aAAK,cAAc,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,CAAC,IAAI,CAAC,GAAG,QAAQ,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;AACrE,aAAK,mBAAmB,GAAG,cAAc,CAAC,aAAa,EAAE,OAAO,CAAC,CAAC;AAClE,oBAAY,cAAc,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;AACpD,oBAAY,mBAAmB,GAAG,cAAc,CAAC,aAAa,EAAE,QAAQ,GAAG,SAAS,GAAG,QAAQ,CAAC,GAC9F,MAAM,CAAC,QAAQ,EAAE,mBAAmB,CAAC,GACrC,MAAM,CAAC,OAAO,EAAE,cAAc,CAAC,CAAC;AAElC,eAAO,MAAM,WAAW,eAAgB,YAAY;;;;;+DAIe;YAAE,QAAQ;gBAAE,QAAQ,EAAE,MAAM,CAAA;aAAE,CAAA;SAAE;;CAalG,CAAC;AAEF,eAAO,MAAM,sBAAsB,gBAAiB,UAAU,EAAE,UAAU,aAAa,KAAG,mBAwGzF,CAAC"}
\ No newline at end of file
Modified:package/out/config/nativeui.d.ts.map
Index: package/out/config/nativeui.d.ts.map
===================================================================
--- package/out/config/nativeui.d.ts.map
+++ package/out/config/nativeui.d.ts.map
@@ -1,1 +1,1 @@
-{"version":3,"file":"nativeui.d.ts","sourceRoot":"","sources":["../../src/config/nativeui.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,IAAI,aAAa,EAAE,MAAM,SAAS,CAAC;AACzD,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAMtC,eAAO,MAAM,sBAAsB,gBAAiB,UAAU,EAAE,KAAG,aAwElE,CAAC"}
\ No newline at end of file
+{"version":3,"file":"nativeui.d.ts","sourceRoot":"","sources":["../../src/config/nativeui.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,IAAI,aAAa,EAAE,MAAM,SAAS,CAAC;AAKzD,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAe,MAAM,UAAU,CAAC;AAEnD,eAAO,MAAM,sBAAsB,gBAAiB,UAAU,EAAE,eAAe,YAAY,KAAG,aAyE7F,CAAC"}
\ No newline at end of file
Modified:package/out/types.d.ts.map
Index: package/out/types.d.ts.map
===================================================================
--- package/out/types.d.ts.map
+++ package/out/types.d.ts.map
@@ -1,1 +1,1 @@
-{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAC3C,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AACnC,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAIvC,oBAAY,YAAY,GAAG;IAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;CAAE,CAAC;AAE1D,MAAM,WAAW,aAAa;IAC5B,MAAM,EAAE,YAAY,CAAC;IACrB,SAAS,CAAC,EAAE,YAAY,CAAC;IACzB,QAAQ,CAAC,EAAE;QACT,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;KACpB,CAAC;CACH;AAED,oBAAY,YAAY,GAAG,IAAI,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,CAAC;AAEzD,oBAAY,OAAO,CAAC,EAAE,GAAG,UAAU,IAAI,CACrC,MAAM,EAAE,YAAY,EACpB,YAAY,EAAE,MAAM,EACpB,YAAY,EAAE,EAAE,EAAE,KACf,OAAO,CAAC,aAAa,CAAC,CAAC;AAC5B,oBAAY,aAAa,GAAG,CAAC,MAAM,EAAE,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I,CACrC,MAAM,EAAE,YAAY,EACpB,YAAY,EAAE,MAAM,EACpB,YAAY,EAAE,EAAE,EAAE,EAClB,UAAU,CAAC,EAAE,YAAY,KACtB,OAAO,CAAC,aAAa,CAAC,CAAC;AAC5B,oBAAY,aAAa,GAAG,CAC1B,MAAM,EAAE,YAAY,EACpB,WAAW,EAAE,UAAU,EAAE,EACzB,UAAU,CAAC,EAAE,YAAY,KACtB,OAAO,CAAC;IAAE,SAAS,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AAEpC,oBAAY,eAAe,GAAG,CAAC,GAAG,EAAE,KAAK,GAAG,IAAI,EAAE,MAAM,CAAC,EAAE,aAAa,KAAK,IAAI,CAAC;AAClF,MAAM,WAAW,cAAc;IAC7B,IAAI,IAAI,IAAI,CAAC;CACd;AAED,oBAAY,QAAQ,GAAG,CAAC,QAAQ,EAAE,QAAQ,EAAE,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,IAAI,CAAC;AAEpE,oBAAY,OAAO,GAAG,CACpB,MAAM,EAAE,MAAM,EACd,YAAY,EAAE,UAAU,EAAE,EAC1B,WAAW,EAAE,OAAO,EACpB,QAAQ,EAAE,eAAe,EACzB,QAAQ,CAAC,EAAE,QAAQ,KAChB,cAAc,CAAC"}
\ No newline at end of file
Modified:package/out/webpack.d.ts.map
Index: package/out/webpack.d.ts.map
===================================================================
--- package/out/webpack.d.ts.map
+++ package/out/webpack.d.ts.map
@@ -1,1 +1,1 @@
-{"version":3,"file":"webpack.d.ts","sourceRoot":"","sources":["../src/webpack.ts"],"names":[],"mappings":"AAAA,OAAO,EAAsB,GAAG,EAAU,MAAM,OAAO,CAAC;AACxD,OAAO,OAAO,EAAE,EAAE,QAAQ,EAAE,aAAa,IAAI,aAAa,EAAE,MAAM,SAAS,CAAC;AAG5E,OAAO,EAAE,OAAO,EAAgB,OAAO,EAAkB,aAAa,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACrH,OAAO,EAEL,gBA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AE,EAAE,aAAa,EAAE,aAAa,KAAK,mBAAmB,GACvF,OAAO,CAAC,EAAE,CAAC,CA+Bb;AAED,eAAO,MAAM,iBAAiB,EAAE,MAAM,OAA6D,CAAC;AACpG,eAAO,MAAM,cAAc,EAAE,CAAC,eAAe,EAAE,eAAe,KAAK,OAAO,CAAC,mBAAmB,CACnC,CAAC;AAE5D,eAAO,MAAM,cAAc,EAAE,aAsB5B,CAAC"}
\ No newline at end of file
Modified:package/CHANGELOG.md
too-big
Modified:package/out/config/common.d.ts
Index: package/out/config/common.d.ts
===================================================================
--- package/out/config/common.d.ts
+++ package/out/config/common.d.ts
@@ -1,6 +1,8 @@
+/// <reference types="node" />
import { Configuration as WebpackConfig, ModuleOptions } from 'webpack';
import { Handler } from '@forge/cli-shared';
+import { Translations } from '@forge/manifest';
export interface ConfigBuilder {
isWatchMode: boolean;
isDebugMode?: boolean;
appDirectory: string;
@@ -19,7 +21,19 @@
declare type RequiredFields<T, F extends keyof T> = T & Required<Pick<T, F>>;
declare type CommonModuleOptions = RequiredFields<ModuleOptions, 'rules'>;
export declare type WebpackEntries = Record<string, string>;
export declare type CommonWebpackConfig = RequiredFields<WebpackConfig, 'module' | 'plugins' | 'output'> & Record<'module', CommonModuleOptions> & Record<'entry', WebpackEntries>;
+export declare const geti18nRule: (i18nConfig: Translations) => {
+ test: RegExp;
+ include: string[];
+ type: string;
+ generator: {
+ filename: ({ module: { resource: i18nResourcePath } }: {
+ module: {
+ resource: string;
+ };
+ }) => string;
+ };
+};
export declare const getCommonWebpackConfig: (entrypoints: EntryPoint[], config: ConfigBuilder) => CommonWebpackConfig;
export {};
//# sourceMappingURL=common.d.ts.map
\ No newline at end of file
Modified:package/out/config/nativeui.d.ts
Index: package/out/config/nativeui.d.ts
===================================================================
--- package/out/config/nativeui.d.ts
+++ package/out/config/nativeui.d.ts
@@ -1,4 +1,5 @@
import { Configuration as WebpackConfig } from 'webpack';
+import { Translations } from '@forge/manifest';
import { EntryPoint } from './common';
-export declare const getNativeUiBuildConfig: (entrypoints: EntryPoint[]) => WebpackConfig;
+export declare const getNativeUiBuildConfig: (entrypoints: EntryPoint[], i18nConfig?: Translations) => WebpackConfig;
//# sourceMappingURL=nativeui.d.ts.map
\ No newline at end of file
Modified:package/out/types.d.ts
Index: package/out/types.d.ts
===================================================================
--- package/out/types.d.ts
+++ package/out/types.d.ts
@@ -1,5 +1,6 @@
import { Logger } from '@forge/cli-shared';
+import { Translations } from '@forge/manifest';
import { Compiler } from 'webpack';
import { EntryPoint } from './webpack';
export declare type BundledFiles = {
[filename: string]: string;
@@ -11,10 +12,10 @@
[key: string]: any;
};
}
export declare type BundleLogger = Pick<Logger, 'info' | 'warn'>;
-export declare type Bundler<EP = EntryPoint> = (logger: BundleLogger, appDirectory: string, endpointPath: EP[]) => Promise<BundlerOutput>;
-export declare type InDiskBundler = (logger: BundleLogger, entrypoints: EntryPoint[]) => Promise<{
+export declare type Bundler<EP = EntryPoint> = (logger: BundleLogger, appDirectory: string, endpointPath: EP[], i18nConfig?: Translations) => Promise<BundlerOutput>;
+export declare type InDiskBundler = (logger: BundleLogger, entrypoints: EntryPoint[], i18nConfig?: Translations) => Promise<{
outputDir: string;
}>;
export declare type WatcherCallback = (err: Error | null, output?: BundlerOutput) => void;
export interface WatcherMonitor {