Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: unknown decorator expression type: MemberExpression #439

Closed
5 tasks done
khaiphan opened this issue Jul 3, 2017 · 1 comment
Closed
5 tasks done

Error: unknown decorator expression type: MemberExpression #439

khaiphan opened this issue Jul 3, 2017 · 1 comment

Comments

@khaiphan
Copy link

khaiphan commented Jul 3, 2017

Make sure these boxes are checked before submitting your issue - thank you!
(If your issue is neither a both bug nor a request, please write in a free style)

Short summary of your issue

Error: unknown decorator expression type: MemberExpression

Input data for reproducing

Configuration

{
  "source": "./src",
  "destination": "./doc",
  "excludes": [
    ["\\.config\\.(js|es6)$"]
  ],
  "experimentalProposal": {
    "classProperties": true,
    "objectRestSpread": true,
    "decorators": true,
    "doExpressions": true,
    "functionBind": true,
    "asyncGenerators": true,
    "exportExtensions": true,
    "dynamicImport": true
  },
  "plugins": [{
    "name": "esdoc-standard-plugin"
  }]
}

Codes

import { observable, action } from 'mobx'
import TransactionColumns from './transactionColumns'
import TransactionColumnsOptions from './transactionColumnsOptions'

export default class {
  @observable.ref transactionColumnsState = [
    'processing_timestamp',
    'core_transaction_id',
    'customer_name_given',
    'processing_result'
  ]
  @observable.ref transactionColumns = TransactionColumns(this.transactionColumnsState)
  @observable.ref transactionColumnsOptions = TransactionColumnsOptions(this.transactionColumns)
  @observable.ref filtered = [{
    id: 'processing_result',
    value: ''
  }]
  @action.bound
  setFiltered (data) {
    this.filtered = data
  }
  @action.bound
  setTransactionsColumnsState (data) {
    this.transactionColumnsState = data
    this.transactionColumns = TransactionColumns(this.transactionColumnsState)
    this.transactionColumnsOptions = TransactionColumnsOptions(this.transactionColumns)
  }
}

Output data

Log

error: could not process the following code.
/Users/khaiphan/Documents/Projects/nfq/alice/src/containers/Transactions/model/transaction.js
0| undefined
1| import { observable, action } from 'mobx'
2| import TransactionColumns from './transactionColumns'
3| import TransactionColumnsOptions from './transactionColumnsOptions'
4|
5| export default class {
6|   @observable.ref transactionColumnsState = [

/Users/khaiphan/Documents/Projects/nfq/alice/node_modules/esdoc/out/src/ESDoc.js:303
        throw e;
        ^

Error: unknown decorator expression type: MemberExpression
    at ClassPropertyDoc._$decorator (/Users/khaiphan/Documents/Projects/nfq/alice/node_modules/esdoc/out/src/Doc/AbstractDoc.js:578:17)
    at ClassPropertyDoc._apply (/Users/khaiphan/Documents/Projects/nfq/alice/node_modules/esdoc/out/src/Doc/AbstractDoc.js:106:10)
    at ClassPropertyDoc._apply (/Users/khaiphan/Documents/Projects/nfq/alice/node_modules/esdoc/out/src/Doc/ClassPropertyDoc.js:30:11)
    at ClassPropertyDoc.AbstractDoc (/Users/khaiphan/Documents/Projects/nfq/alice/node_modules/esdoc/out/src/Doc/AbstractDoc.js:56:10)
    at ClassPropertyDoc (/Users/khaiphan/Documents/Projects/nfq/alice/node_modules/esdoc/out/src/Doc/ClassPropertyDoc.js:24:1)
    at DocFactory._createDoc (/Users/khaiphan/Documents/Projects/nfq/alice/node_modules/esdoc/out/src/Factory/DocFactory.js:455:12)
    at DocFactory._traverseComments (/Users/khaiphan/Documents/Projects/nfq/alice/node_modules/esdoc/out/src/Factory/DocFactory.js:396:20)
    at DocFactory.push (/Users/khaiphan/Documents/Projects/nfq/alice/node_modules/esdoc/out/src/Factory/DocFactory.js:349:20)
    at _ASTUtil2.default.traverse (/Users/khaiphan/Documents/Projects/nfq/alice/node_modules/esdoc/out/src/ESDoc.js:300:17)
    at enter (/Users/khaiphan/Documents/Projects/nfq/alice/node_modules/esdoc/out/src/Util/ASTUtil.js:39:9)

Screen shot of documentation

// attach a image into here

Exception output (if possible)

Log

error: could not process the following code.

Screen shot of documentation

Image

Your environment

  • OS type and version: OSX Sierra v10.12
  • Node.js version: 8
  • ESDoc version: 0.5.2
@h13i32maru
Copy link
Member

I fixed this issue with ESDoc v1.0.3 and esdoc-ecmascript-proposal-plugin.
Please check it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants