最近寫mysql 發現 原來 mysql 在json內容時,也有支援一些操作
https://www.cnblogs.com/chuanzhang053/p/9139624.html
https://medium.com/micheh/%E5%9C%A8-mysql-%E4%BD%BF%E7%94%A8-json-5796a65701ad 再加上 mysql 還有另一個譆能 虛疑欄位 GENERATED ALWAYS AS
http://blog.changyy.org/2017/09/mysql-json-mysql-57.html
基本上可以把json內的某欄位值當成 virutal colume, 直接輸出 覺得這樣可以玩出很多變化 https://www.cnblogs.com/waterystone/p/5626098.html
For logging mulit args with “%O”```
const util = require(‘util’);
function d(…args) {
if (typeof (console) !== ‘undefined’) {
console.log('[Logging]', util.format(…args));
}
}
https://www.darrenhuang.com/core-web-vitals-lcp-fid-cls.html?fbclid=IwAR2-n-h0j-BR73sD4Vsino1ObtjDyVe3xkhNcs7xmtcn14Kk84rWO-06lPs 瀏覽器插件 這是官方出的Chrome挿件,能夠在瀏覽時即時回報該網頁的LCP, FID, CLS。
https://sematext.com/blog/expressjs-best-practices/```
const express = require(‘express’)
const app = express()
const redis = require(‘redis’)
const redisClient = redis.createClient(6379)
async function getSomethingFromDatabase (req, res, next) {
try {
const { id } = req.params;
const data = await database.query()
// Set data to Redis
redisClient.setex(id, 3600, JSON.stringify(data))
res.status(200).send(data) } catch (err) {
console.error(err)
res.status(500)
}
}
function cache (req, res, next) {
const { id } = req.
https://1loc.dev/
In personal setting.json for vs code```
“eslint.workingDirectories”: [
{ “mode”: “auto” }
],