Common front-end components for Web using the Tesseract design system, written for React. https://make.modal.sh/tesseract/web/react/common
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

26 lines
518 B

  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. webpack(...args) {
  11. const oldWebpack = e.webpack(...args)
  12. const [config, { defaultLoaders, }] = args
  13. config.module.rules.push({
  14. test: /\.(ts|tsx)$/,
  15. include: [path.resolve(__dirname, '../react-common/')],
  16. use: [defaultLoaders.babel],
  17. })
  18. return oldWebpack
  19. }
  20. }