Skip to content

Latest commit

 

History

History
925 lines (625 loc) · 55.7 KB

CHANGELOG.md

File metadata and controls

925 lines (625 loc) · 55.7 KB

merchant-center-application-template-starter

17.2.11

Patch Changes

17.2.10

Patch Changes

17.2.9

Patch Changes

17.2.8

Patch Changes

17.2.7

Patch Changes

17.2.6

Patch Changes

17.2.5

Patch Changes

17.2.4

Patch Changes

17.2.3

Patch Changes

17.2.2

Patch Changes

17.2.1

Patch Changes

17.2.0

Minor Changes

  • 4f7e081 #1948 Thanks @emmenko! - Allow to pass the application routes as children of <ApplicationShell>, instead of using the render prop. When doing so, the application entry point routes are automatically configured according to the entryPointUriPath defined in the custom-application-config.json.

    Note that it's still possible to use the render prop. However, for most of the cases it should suffice to rely on the pre-configured routes.

    const AsyncApplicationRoutes = React.lazy(
      () => import('../../routes' /* webpackChunkName: "starter-routes" */)
    );
    
    -export const ApplicationStarter = () => (
    -  <Switch>
    -    {
    -      /* For development, it's useful to redirect to the actual
    -      application routes when you open the browser at http://localhost:3001 */
    -      process.env.NODE_ENV === 'production' ? null : (
    -        <Redirect
    -          exact={true}
    -          from="/:projectKey"
    -          to="/:projectKey/training-custom-app"
    -        />
    -      )
    -    }
    -    <Route
    -      path="/:projectKey/training-custom-app"
    -      component={AsyncApplicationRoutes}
    -    />
    -    {/* Catch-all route */}
    -    <RouteCatchAll />
    -  </Switch>
    -);
    -ApplicationStarter.displayName = 'ApplicationStarter';
    
    const EntryPoint = () => (
      <ApplicationShell
        environment={window.app}
        onRegisterErrorListeners={({ dispatch }) => {
          Sdk.Get.errorHandler = (error) =>
            globalActions.handleActionError(error, 'sdk')(dispatch);
        }}
        applicationMessages={loadMessages}
        DEV_ONLY__loadNavbarMenuConfig={() =>
          import('../../../menu.json').then((data) => data.default || data)
        }
        featureFlags={FEATURE_FLAGS}
    -    render={() => <ApplicationStarter />}
    -  />
    +  >
    +    <AsyncApplicationRoutes />
    +  </ApplicationShell>
    );

    Furthermore, the test-utils of the @commercetools-frontend/application-shell have now a new option to enable this opt-in behavior of rendering the application with pre-configured routes. To enable this option, pass the disableAutomaticEntryPointRoutes: false to the renderApp or renderAppWithRedux functions.

    Note that you also need to provide the environment.entryPointUriPath in order for the routes to be correctly configured.

    -renderApp(<ApplicationStarter />, {
    +renderApp(<ApplicationRoutes />, {
      route: '/my-project/training-custom-app'
    +  environment: {
    +    entryPointUriPath: 'training-custom-app',
    +  },
    +  disableAutomaticEntryPointRoutes: false,
    });

Patch Changes

17.1.0

Minor Changes

  • bb65fa1 #1949 Thanks @emmenko! - The webpack.config.dev.js and webpack.config.prod.js files are not required anymore to be defined in the application folder and can be removed. The default behavior is now implicitly implemented in case the config file is not found. The default behavior requires the following paths to exist:

    • <application_folder>/dist
    • <application_folder>/src
    • <application_folder>/src/index.js

    You can still use the config files if you need to configure more specific behaviors.

Patch Changes

17.0.17

Patch Changes

17.0.16

Patch Changes

17.0.15

Patch Changes

17.0.14

Patch Changes

17.0.13

Patch Changes

17.0.12

Patch Changes

17.0.11

Patch Changes

17.0.10

Patch Changes

17.0.9

Patch Changes

17.0.8

Patch Changes

17.0.7

Patch Changes

17.0.6

Patch Changes

17.0.5

Patch Changes

17.0.4

Patch Changes

17.0.3

Patch Changes

17.0.2

Patch Changes

17.0.1

Patch Changes

17.0.0

Major Changes

  • 633d8c7 #1805 Thanks @emmenko! - Remove the CLI flag --use-local-assets. The default behavior of mc-scripts compile-html now is to compile the assets locally, which is the only reasonable thing to do.

    Furthermore, the @commercetools-frontend/mc-http-server package has been deprecated and won't be published anymore. With the compile-html command there is no need to have a pre-configured HTTP server anymore.

    When running the mc-scripts compile-html command, the index.html is compiled for production usage and it lives in the public folder, together with the other static assets. This is all you need to deploy your application. You can decide to deploy the Custom Application statically to one of the popular cloud providers, or serve the files on your own using a static server.

    For example, to run locally the Custom Application using the production bundles:

    NODE_ENV=production MC_APP_ENV=development dotenv -- \
      mc-scripts compile-html \
      --transformer @commercetools-frontend/mc-dev-authentication/transformer-local.js
    
    mc-scripts serve

Patch Changes

16.11.13

Patch Changes

16.11.12

Patch Changes

16.11.11

Patch Changes

16.11.10

Patch Changes

16.11.9

Patch Changes

16.11.8

Patch Changes

16.11.7

Patch Changes

16.11.6

Patch Changes

16.11.5

Patch Changes

16.11.4

Patch Changes

16.11.3

Patch Changes

16.11.2

Patch Changes

16.11.1

Patch Changes

16.11.0

Minor Changes

  • 4216b92 #1685 Thanks @emmenko! - Refactor i18n package to consume compiled data from ui-kit translation messages. Furthermore, the @commercetools-frontend/i18n now exposes a compiled-data folder as well: @commercetools-frontend/i18n/compiled-data. This can be used the load pre-compiled messages and thus improving the runtime performance.

    Furthermore, the mc-scripts extract-intl command has been deprecated in favor of the more official message extraction with the @formatjs/cli: https://formatjs.io/docs/getting-started/message-extraction.

Patch Changes

16.10.9

Patch Changes

16.10.8

Patch Changes

16.10.7

Patch Changes

16.10.6

Patch Changes

16.10.5

Patch Changes

16.10.4

Patch Changes

16.10.3

Patch Changes

16.10.2

Patch Changes

16.10.1

Patch Changes

16.10.0

Minor Changes

  • 728024c #1626 Thanks @emmenko! - This release introduces the usage of a new configuration file format and marks the deprecation of the env.json and headers.json files.

    For all the necessary information about migrating to the new configuration file, please read the release notes.

Patch Changes

16.9.9

Patch Changes

16.9.8

Patch Changes

  • 364e711 #1621 Thanks @renovate! - feat(deps: add support for react-intl v5 through peer dependencies fix(deps): update dependency react-intl to v5

16.9.7

Patch Changes

16.9.6

Patch Changes

16.9.5

Patch Changes

16.9.4

Patch Changes

16.9.3

Patch Changes

16.9.2

Patch Changes

16.9.1

Patch Changes

16.9.0

Minor Changes

Patch Changes

16.8.9

Patch Changes

16.8.8

Patch Changes

16.8.7

Patch Changes

16.8.6

Patch Changes

16.8.5

Patch Changes

16.8.4

Patch Changes

16.8.3

Patch Changes

16.8.2

Patch Changes

  • a19adb0 #1495 Thanks @tdeekens! - Add apollo-client as dependency as it is peer dependency of react-apollo.

16.8.1

Patch Changes