2017-06-08 9 views
8

We are using JsDoc to create our document of reactjs pages. All comment we wrote as per the jsDoc rule but still it showing below message for some page:Jak uzyskać dokładny komunikat o błędzie JsDoc w formacie reactjs?

BŁĄD: Nie można analizować D: \ Przykład \ src \ reduktorów \ example.js: nieoczekiwany tokenów

I am not getting the error in other pages, we wrote the comment same way but for some pages it is throwing above error. How can I get the exact error message and line number where it is failing?

Odpowiedz

2

How can I get the exact error message and line number where it is failing?

Command-line arguments to JSDoc zapewnić --verbose opcji, które powinny zapewnić LOG szczegółowych informacji JSDoc działa. Niestety nie poda dokładnego numeru linii.

To, o co prosisz, jest dostępne jako otwarte zapytanie na GitHub: Option to print error stack. Jak można się domyślić, nie jest to jeszcze zaimplementowane. Możesz używać pracy dookoła, opublikowanej przez iPherian w tym samym wątku. To obejście da ci numer linii i kolumnę błędu.

EDIT:

W wersji JSDoc "3.5.0-dev" (current development master) Funkcja do linii druku i numer kolumny o błędach jest realizowany i dostępne. Po zainstalowaniu aktualnej wersji rozwojowej ...

npm install git+https://github.com/jsdoc3/jsdoc.git 

i systemem JSDoc przeciwko źródła JS

>"C:\folder\node_modules\.bin\jsdoc.cmd" AppScripts -d bin/Reference --verbose 

błędu wraz z numerami wierszy i kolumn są drukowane na wyjściu ...

enter image description here

Powiązane problemy