modern.js

Modern.js is a web engineering system, including a web framework and a npm package solution.

MIT License

Downloads
1.7M
Stars
4.2K
Committers
117

Bot releases are hidden (Show)

modern.js - v1.7.1

Published by caohuilin about 2 years ago

Bug Fix:

#1441

fix: fix not found analyze/cli when change config

fix: 修复修改配置重启时找不到 analyze/cli

#1441

fix: plugin runtime dependencies

fix: 修复 runtime 插件依赖

modern.js - v1.7.0

Published by caohuilin about 2 years ago

Features:

  • #1397

    feat(webpack): let css-loader generate ESModules

    feat(webpack): css-loader 生成的产物格式由 CommonJS 调整为 ESModules

  • #1404

    chore(runtime): merge @modern-js/plugin-state to @modern-js/runtime

    chore(runtime): 合并 @modern-js/plugin-state@modern-js/runtime

  • #1410

    feat: support Pipe and Middleware operators

    feat: 支持 Pipe 和 Middleware 操作符

  • #1404

    chore(create-request): remove @modern-js/plugin-ssr from @modern-js/create-request

    chore(runtime): @modern-js/create-request 中移除 @modern-js/plugin-ssr 依赖

  • #1404

    chore(utils): remove unused code

    chore(utils): 移除无用代码

  • #1415

    chore(server): delete unused @modern-js/server-utils dependence

    chore(server): 删除未使用的 @modern-js/server-utils 依赖

  • #1412

    feat(webpack): support source.preEntry config

    feat(webpack): 新增 source.preEntry 配置项

  • #1404

    chore(runtime): merge @modern-js/plugin-router to @modern-js/runtime

    chore(runtime): 合并 @modern-js/plugin-router@modern-js/runtime

  • #1404

    chore(runtime): merge @modern-js/plugin-ssr to @modern-js/runtime

    chore(runtime): 合并 @modern-js/plugin-ssr@modern-js/runtime

  • #1404

    chore(runtime): remove @modern-js/create-request from @modern-js/runtime

    chore(runtime): @modern-js/runtime 中移除 @modern-js/create-request 依赖

  • #1395

    chore(bff): remove @modern-js/bff-runtime from @modern-js/runtime dependence

    chore(bff): @modern-js/runtime 中移除 @modern-js/bff-runtime 依赖

  • #1415

    chore(server): merge @modern-js/hmr-client to @modern-js/server

    chore(server): 合并 @modern-js/hmr-client@modern-js/server

  • #1414

    fix: using typeof window to determine the browser environment is not accurate

    fix: 使用 typeof windows 判断浏览器环境不够准确

  • #1415

    chore(app-tools): merge @modern-js/analyze to @modern-js/app-tools

    chore(app-tools): 合并 @modern-js/analyze@modern-js/app-tools

  • #1391

    chore(generator): use module-tools bundle function to bundle generator package

    chore(generator): 使用 module-tools 的 bundle 功能实现生成器打包

Bug Fix:

  • #1413

    fix: ssg build error when multi entries

    fix: 修复多入口下 SSG 构建错误

  • #1381

    fix: runtime package ssr path export field

    fix: 修复 plugin-runtime ssr 路径导出字段

  • #1407

    fix: the SSG callback is called once for each baseUrl, when a user configures multiple baseUrl.

    fix: 当用户配置了多个 baseUrl 时,将会为每个 baseUrl 调用一次 SSG 回调函数。

  • #1416

    fix: the _SERVER_DATA injection twice causes the prod-server route error.

    fix: _SERVER_DATA 二次注入,导致服务器路由错误

  • #1408

    fix(webpack): failed to import SVG with query from a CSS file

    fix(webpack): 修复从 CSS 文件中引用带 query 的 SVG 时出现报错的问题

  • #1418

    fix: package exports field

    fix: 修复包导出字段

  • #1405

    fix: monorepo new command plugin path

    fix: 修复 monorepo tools new 命令计算插件路径

  • #1403

    fix: Additional compilation fields

    fix: 补充 compilation 字段

  • #1409

    fix: allow BFF function to return void

    fix: 允许 BFF 函数返回 void

modern.js - v1.6.4

Published by caohuilin about 2 years ago

Features:

  • #1388

    chore(testing): merge @modern-js/testing-plugin-bff to @modern-js/plugin-testing

    chore(testing): 合并 @modern-js/testing-plugin-bff@modern-js/plugin-testing

  • #1388

    chore(testing): delete @modern-js/bff-utils

    chore(testing): 删除 @modern-js/bff-utils

  • #1388

    chore(testing): merge @modern-js/testing to @modern-js/plugin-testing

    chore(testing): 合并 @modern-js/testing@modern-js/plugin-testing

  • #1389

    feat: add addRuntimeExports hooks for module-tools

    feat: 为 module-tools 添加 addRuntimeExports 钩子

Bug Fix:

  • #1383

    fix: the <title> tag in html template will replace by empty content, when deveploper open ssr.

    fix: 当开启SSR时,html 中的 <title> 标签将被空白内容替换。

  • #1386

    fix: fix bff hot reload not works when has app.ts

    fix: 修复有 app.ts 的时候, bff 热更新不生效的问题

  • #1386

    fix: export http status

    fix: 暴露 http 状态码

modern.js - v1.6.3

Published by caohuilin over 2 years ago

Features:

  • #1337

    chore(generator): remove unbundle from generator options

    chore(generator): 不再支持通过 new 命令开启 unbundle 功能

  • #1352

    chore(core): move Hooks types define to @modern-js/core

    chore(core): 移动 Hooks 类型定义到 @modern-js/core

  • #1352

    chore(plugin-i18n): merge @modern-js/i18n-cli-language-detector to @modern-js/plugin-i18n

    chore(plugin-i18n): 合并 @modern-js/i18n-cli-language-detector 包到 @modern-js/plugin-i18n 包作为子路径

  • #1361

    feat: rumtime config types

    feat: 补充 runtime 配置类型

  • #1336

    feat: support ListenOptions for prod-server

    feat: server 支持传入 listernOptions 参数

  • #1352

    chore(core): merge @modern-js/load-config package to @modern-js/core utils

    chore(core): 合并 @modern-js/load-config 包到 @modern-js/core 包作为 utils 函数

  • #1353

    feat: add onApiChange hook for bff hot reload

    feat: 为 BFF 热更新优化,添加 onApiChange 钩子

  • #1335

    feat: optimize release note

    feat: 优化 Release Note 格式

  • #1350

    feat: @modern-js/module-tools remove @modern-js/plugin-analyze plugin

    feat: @modern-js/module-tools 移除 @modern-js/plugin-analyze 插件

  • #1344

    feat: prod-server supports that load server env from .env.\*

    feat: prod-server 支持从 .env.* 文件加载服务器环境变量

  • #1317

    perf(webpack): improve getSourceInclude performance

    perf(webpack): 优化 getSourceInclude 执行性能

  • #1350

    feat: @modern-js/plugin-storybook add @modern-js/plugin-analyze plugin

    feat: @modern-js/plugin-storybook 添加 @modern-js/plugin-analyze 插件

  • #1352

    chore(generator-utils): tidy up @modern-js/generator-utils func

    chore(generastor-utils): 整理 @modern-js/generator-utils 导出方法

  • #1352

    chore(types): delete http-proxy-middleware dependence(unused)

    chore(types): 删除未使用依赖 http-proxy-middleware

  • #1352

    chore(babel-chain): merge @modern-js/babel-chain to @modern-js/babel-preset-base

    chore(babel-chain): 合并 @modern-js/babel-chain@modern-js/babel-preset-base

  • #1339

    chore(plugin-storybook): remove @modern-js/esbuild-compiler from dependencies

    chore(plugin-storybook): 移除 @modern-js/esbuild-compiler 依赖

Bug Fix:

  • #1354

    fix(webpack): failed to analyze bundle

    fix(webpack): 修复使用 bundle analyze 时报错的问题

  • #1343

    fix: ignore cjs and mjs in d.ts bundle

    fix: 对 d.ts 做 bundle 时忽略 cjs 和 mjs 资源

  • #1349

    feat: update codesmith json api version

    feat: 升级 @modern-js/codesmith-api-json 版本

  • #1346

    fix(webpack): failed to compile .cjs,.cts,.mts file

    fix(webpack): 修复无法编译 .cjs,.cts,.mts 文件的问题

  • #1343

    fix: monorepo-tools new command plugin params not work

    fix: 修复 monorepo-tools new 命令 plugin 参数不生效问题

  • #1343

    fix(generator-plugin): remove addManyFiles destination empty validate

    fix(generator-plugin): 移除 addManyFiles destination 参数为空的校验

modern.js - v1.6.2

Published by caohuilin over 2 years ago

Features:

[#1313] chore(webpack): refactor webpack config, split modules (chore(webpack): 重构 webpack 配置,拆分模块)

[#1323] feat: change webpack output.publicPath for plugin-storybook (feat: 修改 plugin-storybook 的 webpack output.publicPath 配置)

[#1325] perf(webpack): optimize terser default options (perf(webpack): 优化 Terser 默认压缩配置,提升压缩率)

[#1306] feat: add gen-release-note command to generator template (feat: 生成器模板增加 gen-release-note 命令)

[#1326] feat: optimize implentation of registerModernRuntimePath (feat: 优化 registerModernRuntimePath 的实现)

Bug Fix:

[#1319] fix: use client init data first if exist (fix: 优先使用用户定义的 init 数据)

[#1330] fix: ssg load plugin correctly(fix: 修复 SSG 加载插件不正确问题)

[#1327] Add additionalProperties: false to the schema of output.buildConfig (fix: output.buildConfig 的 schema 增加 additionalProperties: false 配置)

[#1324] fix(webpack): should not inject CSS sourcemap in js bundles (fix(webpack): 修复使用 style-loader 时会将 CSS 的 SourceMap 打包到 JS 中的问题)

[#1320] fix(webpack): failed to import SVG from a CSS file in some cases (fix(webpack): 修复从 CSS 文件中引用 SVG 图片时,可能会出现编译报错的问题)

[#1331] fix(css-config): css minify not work when using style-loader (fix(css-config): 修复使用 style-loader 时,CSS 代码未被压缩的问题)

modern.js - v1.6.1

Published by targeral over 2 years ago

Features

  • @modern-js/module-tools 模块开发工具构建功能底层重构
    • 提供全新的构建配置。新增 output.buildConfigoutput.buildPreset 配置。
    • 底层支持 speedy 进行 bundle 构建。新增 tools.speedy 配置
    • 移除内部并行构建的逻辑,修复在构建过程中偶尔出现的找不到文件的问题
    • 兼容当前构建配置 output.packageMode 以及 output.packageFields,并提供了 @deprecated 标记和提示。
    • 新增和标记了构建相关 cli 参数。
    • 更新构建过程中(普通模式和watch模式)的输出 Log 的内容。
modern.js - v1.5.0

Published by caohuilin over 2 years ago

Features

  • 提供一系列的 BFF 操作符,拓展现有 BFF 语法,提升 BFF 的易用度和功能 #1220
  • 预打包 css-loader #1252
  • 实现懒加载 webpack 插件,优化 webpack 启动性能 #1281
  • 支持 twin.macro #1232
  • 支持在 App.init 中返回数据,在 context 中通过 initialData 获取,并支持在 SSR 渲染时插入到 HTML window._SSR_DATA#1265
  • @modern-js/plugin-jarvis 依赖内置到工程方案工具包(@modern-js/app-tools@modern-js/module-tools@modern-js/monorepo-tools)中,并移除初始化项目时 @modern-js/plugin-jarvis 依赖 #1267
  • 优化 dev 命令日志展示,不展示 type-check 过程信息,只展示对应错误信息 #1283
  • 移除 package-json 依赖,优化用户依赖大小 #1292
  • 简化插件机制使用姿势,避免出现 Can't call useContainer out of scope 错误 #1255
  • 增加 server.watchOptions 配置,支持配置 chokidar 文件监听规则 #1290
  • 支持 SSR Render 时在 App.init 或者插件 init 钩子函数中通过 setHeaderstatus 设置 Response 的 Header 和 statusCode #1276
  • 优化 gen-release-note 命令自定义参数,支持异步函数 #1280
  • 升级 devcert 版本号至 v1.2.2 #1252
  • babel-plugin-import 支持忽略未安装的依赖 #1275
  • 升级 @babel/runtime 版本至 ^7.18.0 #1284

Bug Fix

  • 修复约定式路由项目中 App.init 函数不生效问题 #1264
  • 修复生成器模板 css 文件中文错误 #1253
  • babel/registerts-node 已经使用的场景下,无需启用 esbuild-register #1293
modern.js - v1.4.3

Published by caohuilin over 2 years ago

Features

  • 增加 modern change-stauts 命令,支持查看当前分支 chagneset 状态 #1218
  • 升级 changesets 配置中 schema 依赖的版本至 2.0.0 #1226
  • 调整 source.moduleScopes 行为,仅在配置时限制源代码引用路径。#1211 | DOC source.moduleScopes
  • 优化 config/upload 目录下 js 文件压缩策略, 忽略 .min.js 结尾的文件。#1214 | DOC config/upload
  • tools.webpack 配置中 addRulesappendPluginsprependPlugins 方法简化 #1219 | DOC tools.webpack
  • 移除 farrow-http 依赖,减小包依赖体积 #1221
  • 升级 devcert 依赖至 v1.2.2 #1222
  • 调整 webpack babel-loaderts-loader 编译文件策略 #1241
  • 优化 modern start 命令启动时间 #1244
  • 增加 modern gen-release-note 命令,支持根据 changeset 自动生成 Release Note #1226

Bug Fix

  • 修复应用项目创建入口是 .eslintrc.js 文件位置问题 #1217
  • 修复 applyOptionsChain 类型问题 #1224
  • 修复 createApp 返回组件不可直接被加载问题 #1228
  • 修复在 CI 环境未展示 webpack 构建时间日志问题 #1227
  • 修复 tools.babel 配置中 addIncludes 工具函数类型报错问题 #1235
  • 修复插件 API 类型导出问题 #1239
  • 修复微前端插件类型声明 #1216
  • 删除 Eslint 配置中的 prettier 配置,支持用户使用项目目录的 .prettierrc 文件配置格式化代码 #1243
  • 调整 storybook 默认产物目录 ./dist/storybook-static #1237
  • 修复 tools.terser 类型 #1247
  • 修复 modern bump 命令未支持 ignore 参数 #1246
  • 修复 ssrByEntries[name] 存在时 SSR 未打包问题 #1249
  • 修复 windows 场景下 babel 插件路径不存在报错问题 #1240
  • 修复加载用户 modern.config.js 中自定义插件失败问题 #1245
  • 修复 babel-loader 编译未忽略 api 目录问题 #1248
modern.js - v1.4.2

Published by caohuilin over 2 years ago

Features

  • tools.postcss 支持通过 addPlugins 方法添加插件 1183 | DOC tools.postcss
  • 应用项目增加 inspect 命令,支持查看当前最终的 webpack 配置 1189 | DOC inspect 命令
  • tools.lesstools.sass 配置支持 addExcludes 方法 1187 | DOC tools.less DOC tools.sass
  • tools.tsLoader 配置支持 addIncludesaddExcludes 方法 1196 | DOC tools.tsLoader
  • 预打包 babel 相关插件进行构建优化 1192
  • tools.babel 配置支持 addPluginsaddPresetsremovePluginsremovePresetsaddIncludesaddExcludes 方法 1200 | DOC tools.babel
  • @modern-js/create 支持通过 config 中增加 successInfo 字段值自定义创建项目成功展示信息 1207 | DOC 工程方案配置
  • 优化 @modern-js/create 默认创建 Monorepo 的成功展示信息 1207
  • 优化微前端 garfish 插件的子应用渲染逻辑 1208

Bug Fix

  • 修复 unbundle 模式下自定义 globalVars 不生效问题 1177
  • 修复 Typescript 配置插件对 node_modules 中文件路径不生效 1181
  • 修复 devServer.headers 不生效问题 1193
  • 修复使用 Arco Design 图标时构建导入两次问题 1194
  • 修复 bootstrap 函数第二个参数不支持传入 DOM 节点 1198
modern.js - v1.4.1

Published by caohuilin over 2 years ago

  • 支持禁用热更新
  • 升级 Electron 生成器模板 electron-builder 版本
  • 升级 @babel/runtime 版本号至 7.18.0
  • dev 命令支持 --analyze 参数
  • build 和 deploy 命令支持自定义配置文件
  • 修复 dev 命令 --config 参数不生效
  • 修复 bff 未编译 shared 目录代码
modern.js - v1.4.0

Published by caohuilin over 2 years ago

  • bootstrap 函数支持在未传递 DOMId 时返回 React 组件
  • Runtime 支持配置 AppConfig 类型
  • 优化 SSR 打包策略
  • 修复 node_modules 中 CSS 模块编译问题
modern.js - v1.3.10

Published by xuchaobei over 2 years ago

  • 支持通过 CHAIN_ID 修改 html-webpack-plugin 配置。
  • BFF Schema 支持传参。
  • 支持根据入口 server.ssrByEntries 构建 SSR bundle。
  • 一些问题修复。
modern.js - v1.3.9

Published by caohuilin over 2 years ago

  • 支持 tools.webpackChain 配置
  • @modern-js/plugin 支持多版本
  • SSR 支持 globalVars
  • 修复 babel-chain preset 不生效问题
  • 修复 disableCssModuleExtension 配置为 true 时 css 编译错误问题
  • 预打包 tsconfig-paths 和 nanoid
modern.js - v1.3.8

Published by caohuilin over 2 years ago

  • 生成 @svgr/webpack 版本从 v5 到 v6
  • 修改 babel transformRuntime 的 help 配置为 true
  • 默认创建项目安装 husky 依赖
  • @modern-js/create 工具兼容 npm8
  • 修复 dev 命令后触发重编译问题
  • 修复用户 jest 配置未被插件处理问题
  • 修复约定式路由部分全局 layout 不生效问题
  • 修复入口模板样式和 tailwindcss 默认样式冲突问题
  • 修复 tools.polyfill 不生效问题
  • 修复 @modern-js/runtime/model 类型问题
  • 优化 MWA bundle size
modern.js - v1.3.7

Published by caohuilin over 2 years ago

  • 生成器工具删除目录使用 rimraf 代替 del-cli
  • 升级 html-loader 版本从 v2 到 v3
  • 升级 husky 版本从 v3 到 v4
  • 调整生成器 eslint 模板
modern.js - v1.3.6

Published by xuchaobei over 2 years ago

  • webpack loaders 和 plugins 预打包
  • 测试插件增加 afterTest 钩子
  • 日志信息优化
  • 一些问题修复
modern.js - v1.3.3

Published by caohuilin over 2 years ago

  • 预打包一些工具依赖包
  • 移除 max-params 和 max-statements 的 Eslint 规则
modern.js - v1.3.2

Published by caohuilin over 2 years ago

  • ESLint 规则集优化
  • modern.config.ts 文件插件类型定义汇总到 @modern/core 包
  • 修复模块工程方案编译错误
modern.js - v1.3.1

Published by caohuilin over 2 years ago

  • 仓库内部插件迁移至新的插件机制
  • 支持 disableCssExtract 配置
  • 修复 Unbundle 配置及类型问题
  • 修复 devServer.proxy 类型
modern.js - v1.3.0

Published by caohuilin over 2 years ago

  • 修复 tools.less 配置类型
  • 修复 dev.proxy 配置类型
  • 修复 server.routes 配置类型
  • 修复 server.logger 配置类型
  • 修复 server.metrics 配置类型
  • 纯API 服务项目禁止加载 webpack
  • 修复微前端子应用获取不到主应用传递的 props 问题
  • 整体调整 eslint 规则集
  • 重构插件机制
Package Rankings
Top 1.49% on Npmjs.org
Related Projects