Tree-view API not working on Atom environment startup


#1

I am trying to use https://github.com/atom/tree-view#api in my https://github.com/azawawi/atom-perl6-editor-tools/blob/master/lib/file-icons.js#L12 to display custom file icons for Perl 6 file type. The problem is that iconClassForPath(path) is called only after a collapse/expand folder event and not on atom environment
startup.

I have been trying to work around it via the following code but it is not working either.

atom.workspace.getLeftPanels()[0].emitter.emit("tree-view:collapse-directory")
atom.workspace.getLeftPanels()[0].emitter.emit("tree-view:expand-directory")

Your help is appreciated.


#2

Please file a bug on https://github.com/atom/tree-view, preferably with code that you can reproduce the problem.


#3

Already filed it in https://github.com/atom/tree-view/issues/732

Thanks.