Common front-end components for Web using the Tesseract design system, written for React. https://make.modal.sh/tesseract/web/react/common
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

next.config.js 611 B

1234567891011121314151617181920212223242526272829
  1. const path = require('path')
  2. const withMDX = require('next-mdx-frontmatter')({
  3. extension: /\.mdx?$/
  4. })
  5. const e = withMDX({
  6. pageExtensions: ['js', 'jsx', 'ts', 'tsx', 'md', 'mdx']
  7. })
  8. module.exports = {
  9. ...e,
  10. typescript: {
  11. ignoreBuildErrors: true,
  12. },
  13. basePath: '/tesseract/web/react/common',
  14. webpack(...args) {
  15. const oldWebpack = e.webpack(...args)
  16. const [config, { defaultLoaders, }] = args
  17. config.module.rules.push({
  18. test: /\.(ts|tsx)$/,
  19. include: [path.resolve(__dirname, '../react-common/')],
  20. use: [defaultLoaders.babel],
  21. })
  22. return oldWebpack
  23. }
  24. }