ololog icon indicating copy to clipboard operation
ololog copied to clipboard

Chrome Console output does not output location correctly

Open nicewaytodoit opened this issue 4 years ago • 4 comments

While running ololog in React I have noticed that it does not output location file from the point where it is called but shows always as event raised by ololog.js:145.

with location config = false it will show:

3/22/2021, 11:22:14 AM	"My Log>> XXX"       ololog.js:145

with location config = false it will show:

3/22/2021, 11:22:14 AM	"My Log>> XXX"       ololog.js:145
(<computed> → <computed> → <computed> @ pipez.js:47)

while log was raised in the file example.js.

Even in your demo it will output something like: https://xpl.github.io/ololog/

foo ra (<computed> → <computed> → <computed> → <computed> @ pipez.js:48)  ololog.js:145 

nicewaytodoit avatar Mar 22 '21 11:03 nicewaytodoit

Thanks for the report, I'll check that.

xpl avatar Mar 23 '21 07:03 xpl

There was indeed a trouble when linking Ololog as a script tag from another website — stack entries going to that script were not handled correctly. I fixed that.

But that might not fix your issue if you're importing the library using import directive. I'll investigate on that later. What specific framework/bundler do you use?

xpl avatar Mar 23 '21 20:03 xpl

Latest version ololog, latest Webpack fresh test project. Simple create-react-app will give the setup.

nicewaytodoit avatar Mar 25 '21 20:03 nicewaytodoit

It seems that it does not work in "HMR";

image

Haleclipse avatar Aug 04 '21 11:08 Haleclipse