IOS 14. Unexpected token '{'. Import call expects exactly one argument

This is what I have in cesium/Workers/createVerticesFromQuantizedTerrainMesh.js

Happens only for IOS 14.x

using ‘1.109.0’

Hi,

Is this the same case for 1.108 or 1.110?

And are you loading CesiumJS via a script tag, or building the code?

Thanks,
Gabby

Issue was because of last changes, not only IOS, also for firefox <= 114. So i have moved to 1.108 version and it works now. Building with vite config

Got it. Is this occurring with version 1.110 as well? I may suggest an adjustment to your build config.

If you’d like to troubleshoot to ensure future version are working as well, please provide your config and we can take a look.

hey, thanks. this is our cesium plugin config with vite

import fs from 'fs-extra';
import path from 'path';
import serveStatic from 'serve-static';
import { Plugin, UserConfig } from 'vite';

export default function vitePluginCesium(): Plugin {
  let outDir = 'dist';
  let isBuild = false;

  return {
    name: 'cesium',

    config(c, { command }) {
      isBuild = command === 'build';

      if (c.build?.outDir != null) {
        outDir = c.build.outDir;
      }
      const userConfig: UserConfig = {};

      return userConfig;
    },

    configureServer({ middlewares }) {
        middlewares.use('/cesium/', serveStatic('node_modules/cesium/Build/Cesium'));
    },

    async closeBundle() {
      if (isBuild) {
        const cesiumBuildPath = 'node_modules/cesium/Build/Cesium/';
        try {
          await fs.copy(path.join(cesiumBuildPath, 'Assets'), path.join(outDir, 'cesium/Assets'));
          await fs.copy(path.join(cesiumBuildPath, 'ThirdParty'), path.join(outDir, 'cesium/ThirdParty'));
          await fs.copy(path.join(cesiumBuildPath, 'Workers'), path.join(outDir, 'cesium/Workers'));
          await fs.copy(path.join(cesiumBuildPath, 'Widgets'), path.join(outDir, 'cesium/Widgets'));
          await fs.copy(path.join(cesiumBuildPath, 'Cesium.js'), path.join(outDir, 'cesium/Cesium.js'));
        } catch (err) {
          console.error('copy failed', err);
        }
      }
    },
  };
}

So now cesium version is 1.108.0, but the issue is with iPhone 11 and IOS 14.