Skip to content

Commit

Permalink
Removing web components (#2530)
Browse files Browse the repository at this point in the history
Removed web components and all code that references it
  • Loading branch information
VineetBala-AOT authored Jun 3, 2024
1 parent 6d13309 commit d6af0d8
Show file tree
Hide file tree
Showing 11 changed files with 6 additions and 356 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.MD
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
## May 30, 2024

- **Feature** Remove web components [🎟️ DESENG-616](https://apps.itsm.gov.bc.ca/jira/browse/DESENG-616)
- Removed web components and all code that references it

- **Feature** Remove EAO process widget [🎟️ DESENG-626](https://apps.itsm.gov.bc.ca/jira/browse/DESENG-626)
- Removed EAO process widget
- Added migration file to remove EAO process widget attached to any existing engagement
Expand Down
3 changes: 0 additions & 3 deletions met-web/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,6 @@
# production
/build

#web-components
/wc-lib

# misc
.DS_Store
.env.local
Expand Down
41 changes: 0 additions & 41 deletions met-web/config-overrides-wc.js

This file was deleted.

9 changes: 0 additions & 9 deletions met-web/config-overrides.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
const webpack = require('webpack');
const wcConfig = require('./config-overrides-wc');
module.exports = function override(config) {
const isWcBuild = process.argv.indexOf('--wc-build')!==-1;
const fallback = config.resolve.fallback || {};
Object.assign(fallback, {
crypto: require.resolve('crypto-browserify'),
Expand All @@ -25,12 +23,5 @@ module.exports = function override(config) {
fullySpecified: false, // disable the behavior
},
});
if(isWcBuild) {
config.entry = wcConfig.entry;
config.output = {
...config.output,
...wcConfig.output
}
}
return config;
};
1 change: 0 additions & 1 deletion met-web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@
"scripts": {
"start": "react-app-rewired start",
"build": "react-app-rewired build",
"build-wc": "react-app-rewired build --wc-build",
"test": "jest",
"eject": "react-scripts eject",
"lint": "eslint \"src/**/*.{ts,tsx}\"",
Expand Down
9 changes: 3 additions & 6 deletions met-web/src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,9 @@ const getEnv = (key: string, defaultValue = '') => {
} else return process.env[key] || defaultValue;
};

// adding localStorage to access the MET API from external sources(eg: web-components)
const API_URL = localStorage.getItem('met-api-url') || getEnv('REACT_APP_API_URL');
const PUBLIC_URL = localStorage.getItem('met-public-url') || getEnv('REACT_APP_PUBLIC_URL');

// adding localStorage to access the MET Analytics API from external sources(eg: web-components)
const REACT_APP_ANALYTICS_API_URL = localStorage.getItem('analytics-api-url') || getEnv('REACT_APP_ANALYTICS_API_URL');
const API_URL = getEnv('REACT_APP_API_URL');
const PUBLIC_URL = getEnv('REACT_APP_PUBLIC_URL');
const REACT_APP_ANALYTICS_API_URL = getEnv('REACT_APP_ANALYTICS_API_URL');

// Formio Environment Variables
const FORMIO_PROJECT_URL = getEnv('REACT_APP_FORMIO_PROJECT_URL');
Expand Down
121 changes: 0 additions & 121 deletions met-web/src/web-components/components/engagement-banner-wc.tsx

This file was deleted.

41 changes: 0 additions & 41 deletions met-web/src/web-components/components/engagment-tiles-wc.tsx

This file was deleted.

103 changes: 0 additions & 103 deletions met-web/src/web-components/components/wcBase.tsx

This file was deleted.

6 changes: 0 additions & 6 deletions met-web/src/web-components/index.ts

This file was deleted.

Loading

0 comments on commit d6af0d8

Please sign in to comment.