Skip to content

Commit

Permalink
console: Move to rspack
Browse files Browse the repository at this point in the history
  • Loading branch information
malinskibeniamin committed Aug 28, 2024
1 parent 45e63c6 commit e24a2ac
Show file tree
Hide file tree
Showing 11 changed files with 7,694 additions and 1,117 deletions.
5 changes: 1 addition & 4 deletions frontend/.sample.env
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@ PORT=3000
# needed for webpack issue: https://github.com/webpack/webpack/issues/14532
NODE_OPTIONS=--openssl-legacy-provider

# "cra needs webpack 4.29.6, but different version detected"
SKIP_PREFLIGHT_CHECK=true

# forces ui to assume its in dev mode
# - websocket will always connect to "localhost:9090"
# - enables some additional debug logging
Expand All @@ -24,4 +21,4 @@ ESLINT_NO_DEV_ERRORS=true
# REACT_APP_BUILD_TIMESTAMP=32503680000

# Enable all features while developing locally
REACT_APP_ENABLED_FEATURES=SINGLE_SIGN_ON,REASSIGN_PARTITIONS
REACT_APP_ENABLED_FEATURES=SINGLE_SIGN_ON,REASSIGN_PARTITIONS
Original file line number Diff line number Diff line change
@@ -1,22 +1,23 @@
const deps = require('./package.json').dependencies;
module.exports = {
import type { Rspack } from '@rsbuild/core';
import { dependencies } from './package.json';

export const moduleFederationConfig: Rspack.ModuleFederationPluginOptions = {
filename: 'embedded.js',
name: 'rp_console',

exposes: {
'./EmbeddedApp': './src/EmbeddedApp',
'./injectApp': './src/injectApp',
'./config': './src/config.ts',
},

shared: {
...dependencies,
react: {
singleton: true,
requiredVersion: deps.react,
requiredVersion: dependencies.react,
},
'react-dom': {
singleton: true,
requiredVersion: deps['react-dom'],
requiredVersion: dependencies['react-dom'],
},
'@redpanda-data/ui': {
import: '@redpanda-data/ui',
Expand Down
Loading

0 comments on commit e24a2ac

Please sign in to comment.