
Security News
Browserslist-rs Gets Major Refactor, Cutting Binary Size by Over 1MB
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
thinknode
Advanced tools
A fast, flexible and all-in-one web framework for node.js.
ThinkNode 是一款使用 ECMAScript 全新特性开发的 Node.js MVC 框架,使用 async/await 或者 Promise 解决了 Node.js 中异步嵌套的问题,并集成了项目开发中最常用的组件例如 Session、缓存、ORM等,开箱即用,让开发 Node.js 项目更加简单、高效。
src/Admin/Controller/Index.js
export default class extends THINK.Controller {
//构造方法
init(http){
//调用父类构造方法
super.init(http);
this.model = THINK.model('Home/User', {});
}
//控制器默认方法
async indexAction () {
let userInfo = await this.model.where({id: 1}).find();
this.set('userInfo', userInfo);
return this.display();
}
}
src/Admin/Controller/Index.js
export default class extends THINK.Controller {
//构造方法
init(http){
//调用父类构造方法
super.init(http);
this.model = THINK.model('Home/User', {});
}
//控制器默认方法
indexAction () {
return this.model.where({id: 1}).find().then(userInfo => {
this.set('userInfo', userInfo);
return this.display();
}).catch(e => {
return this.error(e.message);
});
}
}
https://www.gitbook.com/book/richenlin/thinknode-doc/
webstorm代码提示插件: File --> Import Settings 选择 /node_modules/thinknode/doc/webstrom_thinknode_settings.jar
npm install -g thinknode_kit
thinknode new project_name
cd project_name
npm install
npm start
打开浏览器,访问http://localhost:3000
richenlin richerdlee
MIT
FAQs
A fast, flexible and all-in-one web framework for node.js.
The npm package thinknode receives a total of 324 weekly downloads. As such, thinknode popularity was classified as not popular.
We found that thinknode demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Research
Security News
Eight new malicious Firefox extensions impersonate games, steal OAuth tokens, hijack sessions, and exploit browser permissions to spy on users.
Security News
The official Go SDK for the Model Context Protocol is in development, with a stable, production-ready release expected by August 2025.