SyntaxError:在严格模式之外尚不支持块范围的声明(let,const,function,class)

时间:2018-03-03 13:25:54

标签: node.js

我正在使用node.js的这个代码,我在单词class

中看到了错误
const _ = require('lodash')
const Market = require('./market')
const signalr = require('signalr-client')
const EventEmitter = require('events')
const cloudscraper = require('cloudscraper')

const wsURI = 'wss://socket.bittrex.com/signalr'
const reconnectWaitTime = 100 //reconnect wait time in ms
const maxCurrenciesPerClient = 20


class MarketManager extends EventEmitter {

    constructor(replayHistory) {

    super()
    this._replayHistory = replayHistory        
    this._setStartValues()
    }

我在很多地方都使用严格模式,但错误相同

0 个答案:

没有答案