refactor: add cache logic
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
local M = {
|
||||
uri = 'https://fanyi-api.baidu.com/api/trans/vip/translate',
|
||||
salt = tostring(math.random(bit.lshift(1, 15))),
|
||||
name = 'baidu',
|
||||
}
|
||||
|
||||
local Trans = require('Trans')
|
||||
|
@@ -1,4 +1,7 @@
|
||||
local M = { no_wait = true, }
|
||||
local M = {
|
||||
no_wait = true,
|
||||
name = 'offline',
|
||||
}
|
||||
|
||||
local db = require 'sqlite.db'
|
||||
vim.api.nvim_create_autocmd('VimLeavePre', {
|
||||
|
Reference in New Issue
Block a user