umi配置WorkboxPlugin, service-worker

时间:2023-8-4   作者:lininn   分类:   热度:457°    
时间:2023-8-4   分类:    热度:457  
安装workbox-webpack-plugin插件 .umirc.ts 增加 import { generalWorkBoxConfig, swScript } from './config/config'; chainWebpack: (config) => { if (process.env.NODE_ENV === 'production') { generalWorkBoxConfig(config); } }, headScripts: process.env.NODE_ENV === 'production' ? [...

阅读全文>>

node使用log4js记录日志

时间:2023-7-4   作者:lininn   分类:   热度:495°    
时间:2023-7-4   分类:    热度:495  
您好,您可以使用log4js模块来记录日志。首先,您需要安装log4js模块。您可以使用以下命令安装它: npm install log4js 然后,您需要在代码中引入log4js模块并配置它。以下是一个示例配置文件: { "appenders": { "file": { "type": "file", "filename": "logs/access.log", "maxLogSize": 10485760, "backups": 3, "compress": true }, "console": { "type": "conso...

阅读全文>>

热门 vue如何使用react组件

时间:2023-6-30   作者:lininn   分类:   热度:539°    
时间:2023-6-30   分类:    热度:539  
Vue 可以使用 React 组件,但是需要使用一个叫做 `vue-reactive-renderer` 的库来实现。 下面是基本的步骤: 1. 安装 `vue-reactive-renderer`: ```bash npm install vue-reactive-renderer ``` 2. 导入 `VueReactiveRenderer`: ```javascript import VueReactiveRenderer from 'vue-reactive-renderer'; ``` 3. 创建一个 React 组件: ```jav...

阅读全文>>

热门 React 组件的“分阶段”渲染

时间:2023-6-9   作者:lininn   分类:   热度:528°    
时间:2023-6-9   分类:    热度:528  
https://zhuanlan.zhihu.com/p/139318295 https://github.com/awmleer/staged-components 也可用 useSWR import { useState } from "react"; import useSWR from "swr"; import "./App.css"; const fetcher = (url) => fetch(url).then((res) => res.json()); function App() { const [count, setCount] ...

阅读全文>>

热门 免费 AI Copilot

时间:2023-6-9   作者:lininn   分类:   热度:549°    
时间:2023-6-9   分类:    热度:549  
用于 Web 的免费 AI Copilot。在任何网站上使用 ChatGPT(插件和 GPT-4)、Bard、Bing 和 Claude,无需复制粘贴。一键编写、重写、总结、翻译、解释或回复任何文本。它还提供了访问 ChatGPT、Bard、Bing 和 Claude 的最快方式,只需按 Cmd/Alt + J。不需要 ChatGPT (OpenAI) 帐户。我们提供免费 AI 来为扩展提供支持,速度与 ChatGPT Plus 一样快,但完全免费!UseChatGPT.AI 是一款免费的 Chrome 扩展程序,它通过增强 ChatGPT(插件和 GPT-4)、Bard、Bing Chat ...

阅读全文>>

返回顶部    首页    手机版本    后花园   会员注册   
版权所有:覆手为雨    站长: lininn