Skip to content
This repository has been archived by the owner on Nov 28, 2022. It is now read-only.

Commit

Permalink
chore(deps): move variable to peerdep (#1080)
Browse files Browse the repository at this point in the history
## 🧰 What's being changed?

This sets `@readme/variable` as a peerDep. Variable is using a context to propagate user variables. So, it needs to be a singleton in the app, otherwise any imported consumers won't be matched the correct provider.

[ticket](https://app.asana.com/0/1199089258199423/1199528380076880/f)
  • Loading branch information
kellyjosephprice authored Dec 4, 2020
1 parent b006844 commit c9ebcee
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/api-explorer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,7 @@
"@readme/oas-form": "^10.0.0",
"@readme/oas-to-har": "^10.0.0",
"@readme/oas-to-snippet": "^10.0.1",
"@readme/syntax-highlighter": "^10.3.1",
"@readme/variable": "^10.0.0",
"@readme/syntax-highlighter": "^10.4.0",
"classnames": "^2.2.5",
"fetch-har": "^4.0.2",
"js-cookie": "^2.1.4",
Expand All @@ -42,6 +41,7 @@
"peerDependencies": {
"@readme/markdown": "^6.21.0",
"@readme/ui": "^1.16.1",
"@readme/variable": "^10.0.0",
"react": "16.x",
"react-dom": "16.x"
},
Expand All @@ -50,6 +50,7 @@
"@readme/markdown": "^6.21.0",
"@readme/oas-examples": "^3.6.0",
"@readme/ui": "^1.16.1",
"@readme/variable": "^10.0.0",
"@testing-library/dom": "^7.26.3",
"css-loader": "^4.3.0",
"eslint": "^7.0.0",
Expand Down
1 change: 1 addition & 0 deletions packages/api-explorer/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ module.exports = {
entry: ['whatwg-fetch', './src/index.jsx'],
externals: {
'@readme/markdown': '@readme/markdown',
'@readme/variable': '@readme/variable',
react: {
root: 'React',
commonjs: 'react',
Expand Down

0 comments on commit c9ebcee

Please sign in to comment.