Comments (9)
Huh, that would be quite a hack (in the good sense of the word). Not really useful, but cool if it works.
Then again, if it worked, someone might find an actual use case. Are you using Amber this way?
from squeakjs.
Not really using, I just tried it as (successful) proof of concept. Besides a better debugger, it was one thing that missed for Lively. It could significantly lower the barrier for newcomers because then they do not need to set up the server etc. And once the working version lasts working forever as a snapshot.
For Amber, I needed very slightly (and in defined way that can be reverted) modify the modules definition to be able to concatenate everything into one file. The idea is that you may even modify these scripts from inside the page and save everything as a new version, but if you are serving it from a proper server, you may push the new versions there or reload the newer versions from the server (mostly for updates of external packages, that may be regular versions that everyone is using, just slightly modified during export/import)
from squeakjs.
The hacks to to libraries were moslty like:
content copyReplaceAll: 'define(function' with: ('define("', prefix, moduleName, '",function').
or
content copyReplaceAll: 'define(factory' with: ('define("', prefix, moduleName, '",factory').
or
content copyReplaceAll: 'define([' with: ('define("', prefix, moduleName, '",[').
from squeakjs.
Not really sure what you mean by "do not need to set up the server". SqueakJS uses IndexedDB as persistent storage, you do not need a server to run in.
from squeakjs.
I know, it is a great feature. However, you need a server for the first time to answer XMLHttpRequests (not big issue, anyway)
from squeakjs.
You do not need a server. You can just drop an image into the /run/
page.
from squeakjs.
Ah, I see, we broke that, because the bundled squeak.js is not in the same dir anymore.
But it can be made to work easily by moving the JS file to the same directory as the html. And it would be even easier, as you say, if we inlined the JS in the HTML using a bundler.
from squeakjs.
Ok, great, I think I we can close this issue, it served its purpose :-)
Btw. when working on Lively, have you considered TiddlyWiki-like self-hosting architecture?
from squeakjs.
That would be a question for Dan - I don't know.
Closing this for now.
from squeakjs.
Related Issues (20)
- Problem with failing primitiveStringHash? | Cannot load metacello.sar HOT 7
- High-Performance JIT HOT 10
- Add inline caches
- Where is the code for opening the onscreen keyboard for iOS? HOT 1
- SoundPlayer has still room for improvement HOT 1
- TypeError: Cannot read property '3' of undefined
- Error on loading squeak.js -- line 29 HOT 2
- Very frequent "primitive 176 not implemented" in debugger running Cuis image HOT 3
- Error: Class not in class table HOT 5
- Custom pointer shapes not shown in Mac Safari HOT 4
- 64 bit Cuis image out of memory HOT 1
- Squeak 6.0 image format unknown HOT 2
- High-DPI not working HOT 9
- Primitive 218 doNamedPrimitiveWithArgs not implemented HOT 1
- Mouse fixed at top left in Firefox for Android HOT 3
- I succeeded in running squeakJS in the web browser. But, ... HOT 1
- I cant open my projects in scratch.js.org HOT 13
- Add file import button HOT 1
- Fix writing Scratch projects HOT 12
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from squeakjs.