The vue-cli/webpack 4 toolchain was the root cause of three shipped
production crashes this week (iterator-spread __spreadArrays RangeError,
stale cache-loader emitting raw vue_1.default for the vue external, and
the TDZ circular-import). Replace it:
- vite.config.ts: lib build of src/wrapper.ts -> dist/package/
viewer.umd.js (IIFE, esnext, minified) + viewer.css + map. vue and
bootstrap-vue stay external (window.Vue / window.BootstrapVue) via
plain global reads - no .default interop possible. process.env is
baked to ({}) via define, matching vue-cli's old defaults.
- vitest.config.ts: jsdom env, single fork, chai-compatible specs run
unchanged. 879 tests pass (was 809 - the json-driven chart/resource
suites now register their dynamic tests properly under vitest).
- import type correctness across the codebase: rolldown rejects
value-imports of type-only exports, so type-only imports are now
written as import type (and mixed imports split). Also fixes
self-contained-state.ts's reassignment of a destructured const.
- Commands.spec.ts: split a two-render test into two its - two
@testing-library renders of Commands in one test interfere under
vitest.
- scripts: package/build -> vite build, test -> vitest run.
- devDeps: +vite +@vitejs/plugin-vue2 +vitest +jsdom +esbuild +events
(browser polyfill for the engine's node 'events' import).
Verified in Chromium against the built bundle: loads with CDN Vue 2 +
BootstrapVue, Rotate sectors completes with and without rotations, zero
pageerrors; the bundle contains no __spreadArrays helpers.
- improve display of taken players in faction wheel
- use icons to show research progress in player area
- show taken sectors and power values of structures in and outside federations for all players
- satellite image is from https://upload.wikimedia.org/wikipedia/commons/2/27/FP_Satellite_icon.svg