Skip to content

Commit

Permalink
Merge pull request #22 from storyofams/chore/deps
Browse files Browse the repository at this point in the history
Chore/deps
  • Loading branch information
BJvdA authored Aug 13, 2021
2 parents 632c1c0 + 0968e0c commit d054d26
Show file tree
Hide file tree
Showing 6 changed files with 1,194 additions and 2,022 deletions.
4 changes: 4 additions & 0 deletions example/next-env.d.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1,6 @@
/// <reference types="next" />
/// <reference types="next/types/global" />
/// <reference types="next/image-types/global" />

// NOTE: This file should not be edited
// see https://nextjs.org/docs/basic-features/typescript for more information.
24 changes: 8 additions & 16 deletions example/next.config.js
Original file line number Diff line number Diff line change
@@ -1,27 +1,19 @@
const path = require('path');
const { TsconfigPathsPlugin } = require('tsconfig-paths-webpack-plugin');

const hasNextBabelLoader = (r) => {
if (Array.isArray(r.use)) {
return r.use.find((l) => l && l.loader === 'next-babel-loader');
}

return r.use && r.use.loader === 'next-babel-loader';
};

module.exports = {
env: {
PASSWORD_PROTECT: process.env.ENVIRONMENT === 'staging',
},
eslint: {
// Warning: This allows production builds to successfully complete even if
// your project has ESLint errors.
ignoreDuringBuilds: true,
},
experimental: {
externalDir: true,
},
webpack(config, options) {
config.module.rules.forEach((rule) => {
if (/(ts|tsx)/.test(String(rule.test)) && hasNextBabelLoader(rule)) {
rule.include = [...rule.include, path.join(__dirname, '..', 'src')];

return rule;
}
});

config.module.rules.push({
test: /\.svg$/,
use: [{ loader: '@svgr/webpack', options: { icon: true, svgo: false } }],
Expand Down
4 changes: 2 additions & 2 deletions example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"@svgr/webpack": "^5.0.1",
"axios": "^0.21.1",
"fontfaceobserver": "^2.1.0",
"next": "^10.0.2",
"next": "^11.1.0",
"next-seo": "^3.3.0",
"object-fit-images": "^3.2.4",
"react": "^17.0.1",
Expand Down Expand Up @@ -82,7 +82,7 @@
"react-select-event": "^4.1.2",
"ts-jest": "^25.0.0",
"ts-loader": "^6.2.1",
"typescript": "^3.7.4"
"typescript": "4.3.2"
},
"eslintConfig": {
"extends": [
Expand Down
Loading

1 comment on commit d054d26

@vercel
Copy link

@vercel vercel bot commented on d054d26 Aug 13, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.