Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simple Bridge Read File and Hello world Demos #18

Merged
merged 3 commits into from
Oct 24, 2013
Merged

Simple Bridge Read File and Hello world Demos #18

merged 3 commits into from
Oct 24, 2013

Conversation

ashishnegi
Copy link
Contributor

Hello World demo is simple, just creates a socket emit and on for 'hello' and 'world'.

Bridge Read File -> gets a proxy of fs variable of nodejs's require('fs').

Then called readFile function for a demo. It is a very simple bridge.

@sihorton
Copy link
Owner

Wow, so if I read your code correctly you just created a proxy for nodejs objects so you can call them from the browser :-) that is a very nice trick and great idea. Maybe we should add that kind of functionality to the offical deskshell clientApi?

sihorton added a commit that referenced this pull request Oct 24, 2013
Simple Bridge Read File and Hello world  Demos
@sihorton sihorton merged commit 87ad5c3 into sihorton:master Oct 24, 2013
@ashishnegi
Copy link
Contributor Author

Earlier i had put the code in ClientApi but then thought that lets make the idea bloom in separate demo.

@sihorton
Copy link
Owner

Yes you are right to do it as a separate demo first. It does has potential to go into the clientApi though. Lets play around with the general idea and when we have used it in a couple of applications and determined best practice and way of providing the proxy for objects in the best way then we can add it. By the way the chrome remote debug protocol (used in chrome developer tools) uses exactly the same approach, so these proxy objects with communication over websocket is a very powerful approach.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants