Skip to content

Commit

Permalink
fix(deps): lint can run locally (#85)
Browse files Browse the repository at this point in the history
* fix(deps): lint can run locally

fixes #84

* fix: build

* wth: idk: gross

* fix: typed webpack config

* fix: use @helia/unixfs v1.4.1

* fix(build): helia-nextjs builds

* fix(helia-webpack): remove ReactDom.render

see https://react.dev/blog/2022/03/08/react-18-upgrade-guide\#updates-to-client-rendering-apis
  • Loading branch information
SgtPooki authored Jul 27, 2023
1 parent 7a558f8 commit 4be4c08
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 8 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
"last 1 Chrome version"
],
"dependencies": {
"@helia/unixfs": "^1.2.1",
"@helia/unixfs": "^1.4.1",
"helia": "^1.0.0",
"react": "^18.2.0",
"react-dom": "^18.2.0"
Expand Down
11 changes: 4 additions & 7 deletions src/index.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
import React from 'react'
import ReactDOM from 'react-dom'
import { createRoot } from 'react-dom/client'
import './app.css'
import App from './app.js'

ReactDOM.render(
<React.StrictMode>
<App />
</React.StrictMode>,
document.getElementById('root')
)
const container = document.getElementById('root')
const root = createRoot(container)
root.render(<App tab="home"/>)
9 changes: 9 additions & 0 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ const paths = {
public: path.resolve(__dirname, './public')
}

/**
* @type {Partial<import('webpack').Configuration>}
*/
const prod = {
mode: 'production',
devtool: false,
Expand All @@ -43,6 +46,9 @@ const prod = {
target: 'browserslist'
}

/**
* @type {Partial<import('webpack').Configuration>}
*/
const dev = {
// Set the mode to development or production
mode: 'development',
Expand Down Expand Up @@ -73,6 +79,9 @@ const dev = {
]
}

/**
* @type {Partial<import('webpack').Configuration>}
*/
const common = {
// Where webpack looks to start building the bundle
entry: [paths.src + '/index.js'],
Expand Down

0 comments on commit 4be4c08

Please sign in to comment.