atom-community / markdown-preview-plus

Markdown Preview + Community Features
https://atom.io/packages/markdown-preview-plus
Other
370 stars 85 forks source link

TypeError: util.atomConfig is not a function #449

Closed ghost closed 4 years ago

ghost commented 5 years ago

i press ctrl+shift+m,then atom show me below [Enter steps to reproduce:]

  1. ...
  2. ...

Atom: 1.34.0 x64 Electron: 2.0.16 OS: Unknown Windows version Thrown From: markdown-preview-plus package 3.7.1

Stack Trace

TypeError: util.atomConfig is not a function

At util.atomConfig is not a function

TypeError: util.atomConfig is not a function
    at addPreviewForEditor (/packages/markdown-preview-plus/lib/main.js:111:30)
    at toggle (/packages/markdown-preview-plus/lib/main.js:92:16)
    at /packages/markdown-preview-plus/lib/main.js:173:36)
    at CommandRegistry.handleCommandEvent (D:/software/Atom/atom-x64-windows/Atom x64/resources/app/static/<embedded>:11:350017)
    at CommandRegistry.dispatch (D:/software/Atom/atom-x64-windows/Atom x64/resources/app/static/<embedded>:11:348492)
    at AtomEnvironment.dispatchApplicationMenuCommand (D:/software/Atom/atom-x64-windows/Atom x64/resources/app/static/<embedded>:1:671034)
    at EventEmitter.t (D:/software/Atom/atom-x64-windows/Atom x64/resources/app/static/<embedded>:1:678418)
    at emitThree (events.js:136:13)
    at EventEmitter.emit (events.js:217:7)

Commands

  4x -9:19.5.0 markdown-preview-plus:toggle (input.hidden-input)
     -7:48.7.0 markdown-preview-plus:toggle-render-latex (input.hidden-input)
  8x -7:44.2.0 core:backspace (input.hidden-input)
     -7:16.5.0 markdown-preview-plus:toggle (input.hidden-input)

Non-Core Packages

markdown-preview-plus 3.7.1 
lierdakil commented 5 years ago

Hi. Thanks for your report.

Judging by the source code, this shouldn't ever happen. I mean, as far as I can tell, unless the package is corrupted somehow it just can't happen. The only thing I can suggest is to try reinstalling the package (i.e. uninstall it and install it again) -- perhaps that will help.