-
thinkjs3 怎么配置端口啊
-
thinkjs3 部署在二级目录 静态资源怎么配置才能访问~
-
## DESC
thinkjs3如何实现静态资源和json接口数据的gzip压缩?
### ENV
OS Platform: mac osx 11
Node.js Version: v8.5.0
ThinkJS Version: 3.1
### code
```js
const compress = require('koa-compress')
..…
-
## DESC
### ENV
OS Platform:
WIN10
Node.js Version:
V8.1.2
ThinkJS Version:
3.2.4
### code
```js
// controller file
async testAction() {
let device_id = 1;
let chann…
-
## DESC
### ENV
OS Platform:win
Node.js Version:v6.11.3
ThinkJS Version:v3.0
### code
```js
// your code here
```
{
"version": "0.2.0",
"configurations": [
{
…
-
@lushijje
```js
class Demo extends think.Sequel {
get schema() {
const DataTypes = think.Sequel.Sequel;
return {
attributes: {
...
},
relations: [
…
-
Node: 8.4
不打开Babel
### 升级指南
1. 导入导出
1. 导入:
```
import Sequelize from 'sequelize';
```
改为
```
const Sequelize = require('sequelize');
```
2. 导出:
```
export defa…
-
## 提一点小疑惑?
看了ThinkJS3.0的文档说3.0抛弃了2.0中的核心架构。
最近将一个cms系统从ThinkJS2.x迁移到ThinkJS3.x过程中发现以前使用的think对象内置的方法依然有效,比如think.md5()、think.uuid()、think.isEmpty()等等。
这些在ThinkJS3.0文档中的think对象描述部分并没提及。
## 弱弱的问一下
…
-
## DESC
想试试用thinkjs3.*做服务器渲染的,下面控制器里面不小心用import引入文件:
```js
const Base = require('./base.js');
var React = require('react');
var renderToString = require('react-dom/server');
var StaticRouter = r…
51kad updated
7 years ago
-
DESC
2.X有扩展错误类型,thinkjs3如何实现呢?
## ENV
Platform: windows
Node.js Version:6.11.1
ThinkJS Version:3.0