porsager / wright

🚀 Work Fast Work Wright
Do What The F*ck You Want To Public License
178 stars 15 forks source link

Doesn't work (on win32) #10

Closed barneycarroll closed 7 years ago

barneycarroll commented 7 years ago

Hey @porsager I really like the look of this but can't seem to get it to work in any way shape or form.

I tried npm installing it (from github) as a dependency on a fresh project and writing my wright.js from scratch, but this yielded no results. I hacked about a bit, couldn't get anything to work. Later on I cloned the repo and installed all deps for the core package and the examples, and still nothing seems to happen beyond launching a chrome instance.

In each case a chrome instance is launched with 2 tabs: 1 at http://localhost:3000/ and 1 showing the dev tools at http://localhost:3001/devtools/inspector.html?ws=localhost:3002/devtools/page/{hash}.

No errors are reported (other than missing favicon, natch), and the loaded DOM is the same regardless of local files: an empty document with the title $ wright /{local_folder_name}. Changing local files doesn't produce any logs in the shell which originated the process, neither does the chrome runtime change at all. The only change I can produce is by reloading either chrome tab, which appends a style element to the head containing an embedded base64-encoded definition for a font-face assigned to wrightopensans.

I'm on a win32 windows machine which may account for something.

Video: wright

If I set debug to 2, I get the following logs. The oom_memory_details.cc(46) happen in slow succession and stop after a while but don't appear to be the result of any ostensible action on my part. 🤔

17:49:19.659 Starting wright...
17:49:20.760 Server started on http://localhost:3000
17:49:23.916 Debug: Waiting for chrome to launch
17:49:24.664 Chrome err: [7296:6632:0103/174924:WARNING:external_registry_loader_win.cc(211)] Error observing HKLM.

17:49:29.731 Chrome err: [7296:6632:0103/174929:WARNING:oom_memory_details.cc(46)] Tab Discards Memory details (435 ms):
Tab [Developer Tools - http://localhost:3000/] 23 MB private, 23 MB shared
Browser 17 MB private, 32 MB shared
Extension [Chrome Media Router] 13 MB private, 18 MB shared
Tab [$ wright /mithril] 8 MB private, 18 MB shared
GPU [] 7 MB private, 18 MB shared

17:49:34.763 Chrome err: [7296:6632:0103/174934:WARNING:oom_memory_details.cc(46)] Tab Discards Memory details (467 ms):
Tab [Developer Tools - http://localhost:3000/] 21 MB private, 23 MB shared
Browser 18 MB private, 33 MB shared
Extension [Chrome Media Router] 13 MB private, 18 MB shared
Tab [$ wright /mithril] 8 MB private, 18 MB shared
GPU [] 7 MB private, 18 MB shared

17:49:39.715 Chrome err: [7296:6632:0103/174939:WARNING:oom_memory_details.cc(46)] Tab Discards Memory details (417 ms):
Tab [Developer Tools - http://localhost:3000/] 21 MB private, 22 MB shared
Browser 19 MB private, 33 MB shared
Extension [Chrome Media Router] 13 MB private, 18 MB shared
Tab [$ wright /mithril] 8 MB private, 18 MB shared
GPU [] 7 MB private, 18 MB shared
porsager commented 7 years ago

Hi Barney..

To start the mithril example could you try to run it like this from the mithril directory?

npm run rollup

Running wright without any arguments as you do in the gif will not do anything currently, but I'm planning to make it start a small interactive guide to walk you through setup for your own environment.

I just updated the readme to have the correct command as well. I changed the mithril example to contain rollup, webpack and browserify examples which is a bit confusing, but I finally have time to do some more work on wright this week.

barneycarroll commented 7 years ago

Right — it's all working great now :)

Thanks!

porsager commented 7 years ago

Great :)

Would love to hear how it works out for you..