视野修炼第124期 | 终端艺术字

欢迎来到第 124 期的【视野修炼 - 技术周刊】,下面是本期的精选内容简介

🔥强烈推荐

  1. figlet.js - 终端生成 ASCII 艺术字体
  2. state-in-url
  3. 语法高亮组件

🔧开源工具&技术资讯

  1. log-vwer - 轻量的日志监控面板
  2. 网站链接检测
  3. 小恐龙二维码生成
  4. 3D 拟物图标资源
  5. Biome V2

下面开始本期内容的介绍,预计阅读时间 6 分钟。

🔥强烈推荐

1. figlet.js - 终端生成 ASCII 艺术字体

js 复制代码
var figlet = require("figlet");

figlet("Hello World!!", function (err, data) {
  console.log(data);
});
md 复制代码
  _   _      _ _        __        __         _     _ _ _
 | | | | ___| | | ___   \ \      / /__  _ __| | __| | | |
 | |_| |/ _ \ | |/ _ \   \ \ /\ / / _ \| '__| |/ _` | | |
 |  _  |  __/ | | (_) |   \ V  V / (_) | |  | | (_| |_|_|
 |_| |_|\___|_|_|\___/     \_/\_/ \___/|_|  |_|\__,_(_|_)

还有 CLI 版本支持

收藏起来,写CLI能用上!

2. state-in-url

将状态信息存储在URL中,便于持久化当下的用户操作后的页面数据,也便于分享复现。

目前支持Next,React Router,Remix。

3. 语法高亮组件

原生的 web component,用于代码高亮。

js 复制代码
import 'syntax-highlight-element';
html 复制代码
<syntax-highlight lang="js">
const a = 1;
</syntax-highlight>

使用非常简单!基于 CSS 自定义高亮API实现。

🔧开源工具&技术资讯

4. log-vwer - 轻量的日志监控面板

用于监控 Node.js 应用程序日志的仪表板,实现应用自托管。

使用也比较简单,支持多种日志存储方式!(数据库,文件,内存)

js 复制代码
// Import the necessary tools
const express = require('express');
const { setupLogger, viewerMiddleware } = require('log-vwer');

// Create your Express app
const app = express();
const PORT = process.env.PORT || 3000;

// This is an async function to make sure we connect to the database *before* starting the server.
async function startServer() {
    // === Part 1: Set up the logger ===
    const logger = await setupLogger({
      serviceName: 'My Awesome E-Commerce App',
      store: 'mongodb',
      mongoUrl: 'mongodb://localhost:27017/my_app_logs',
    });

    // === Part 2: Activate the dashboard ===
    // This tells your app: "When someone goes to /_logs, first check the password, then show the log dashboard."
    app.use('/_logs', myAuthMiddleware, viewerMiddleware(logger));

    // Start your server only after everything is ready
    app.listen(PORT, () => {
      logger.warn(`Server is alive on port ${PORT}. Ready to rock!`);
      console.log(`Log dashboard is live at: http://localhost:${PORT}/_logs`);
    });
}

// Run the function to start the server!
startServer();

5. 网站链接检测

可以检测网页中的外链,死链等情况。

6. 小恐龙二维码生成

Chrome 同款风格

7. 3D 拟物图标资源

8. Biome V2

宣称是首个无需依赖 TypeScript 编译器(tsc)、却仍能提供类型感知规则的 JavaScript 和 TypeScript 代码检查工具。

😛趣图

⭐️强力推荐关注

周刊部分内容来源如下渠道,推荐大家关注。

相关推荐
Asort11 小时前
JavaScript设计模式(六)——适配器模式 (Adapter)
前端·javascript·设计模式
是晓晓吖11 小时前
Puppeteer page.on('response',fn)的最佳实践之等待响应
前端·puppeteer
跟橙姐学代码11 小时前
给Python项目加个“隔离间”,从此告别依赖纠缠!
前端·python·ipython
Cache技术分享11 小时前
202. Java 异常 - throw 语句的使用
前端·后端
_AaronWong12 小时前
Electron全局搜索框实战:快捷键调起+实时高亮+多窗口支持
前端·搜索引擎·electron
笔尖的记忆12 小时前
渲染引擎详解
前端
大明二代12 小时前
为 Angular Material 应用添加完美深色模式支持
前端
请数据别和我作队12 小时前
视频字幕提取工具 ——Video-subtitle-extractor
经验分享·开源·github·字幕提取·vse
weixin_4571260512 小时前
分享几个免费下载抖音、小红书、快手高清图片和视频的在线网站
javascript·python·html
Mintopia12 小时前
🚪 当 Next.js 中间件穿上保安制服:请求拦截与权限控制的底层奇幻之旅
前端·后端·next.js