目录

    打包工具-vite

    vite

    功能特性

    1. import.meta.glob()

      const modules = import.meta.glob('./path/to/files/*.js')
      
      import.meta.glob('./pages/**/!(*.test.[jt]sx*.([jt]sx))')
      
      // 解读:
      // 	./pages: 匹配的文件路径起始部分
      //	/**: 表示可以匹配任意多层的子级目录
      //	/!(*.test.[jt]sx): 表示排除以 .test.jsx / .test.tsx 结尾的测试文件
      //	.([jt]sx): 表示匹配.jsx / .tsx 结尾的文件