Replies: 4 comments 4 replies
-
|
Doubling back on this, I don't get how this integrates with a locally run CLOG instance. Details:
In my case it is php -S localhost:9000:
In my case we just put the basic boilerplate in the local index.html file seved with the php web server: Question for you for Spinneret with the hope I can get this working on the php webserver for testing: The above samples configure boot.js so it is aware of it's new location under a new server. HOW does anything on the new server interact with the CLOG instance sitting on port N2? I presume we would be calling /this or /that route, but how is that executed on the N2 CLOG port and then updates the dom on the Spinneret/php webserver pages sitting on the N1 port? What am I not understanding here? |
Beta Was this translation helpful? Give feedback.
-
|
Clog isn't going to work if you aren't using a common lisp server. Spinneret is a library for generating HTML from Lisp. |
Beta Was this translation helpful? Give feedback.
-
|
Heads up, this also works with Apache / php webserver, etc. A quick demo:
to this: This tells the boot.js code to connect to port 8000 on the 127.0.0.1 via web sockets, which is were we conveniently have CLOG already listening. HINT!!! You must not change this, it is important as CLOG loads up data from your local clog directory: adr = adr + '/clog';
More hacking to do ... if anyone has any cool ideas or tests, post them here, I would love to see them. |
Beta Was this translation helpful? Give feedback.
-
|
And, here is how you get another web server to render CLOG content running somewhere else on the network using web sockets:
From your work computer, open up your browser to http://clog to see the content that the php server will render below.
to this: This tells the boot.js code to connect to port 8000 on the http://clog server via web sockets, which is were we conveniently have CLOG already listening. HINT!!! You must not change this, it is important as CLOG loads up data from the clog directory: adr = adr + '/clog';
Well, that was fun. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi all,
I just wanted to share how I managed to integrate CLOG into an already existing website that used Ningle + CLACK.
But this would work for any HTTP server.
For context all of my webpages are generated using Spinneret (HTML5) + LASS (CSS).
To integrate into CLOG I had to do the following:
Start CLACK (for my original website) on port N1
Start CLOG on port N2
With Ningle create 2 routes one that returns a custom version of
boot.js@ /js/boot.jsand the other returns
jquery.min.js@ /js/jquery.min.jsI modified line 93 of
boot.jsto beFinally I add my #'clog:initialize
And add the scripts to the pages I want to integrate into CLOG.
I am pointing this out because the tutorial that exists as an example of integrating into an existing project is ridiculous and using static .html files.
It would be nice if the /js/boot.js was written using Parenscript.
If I come up with a better solution I'll share it.
Beta Was this translation helpful? Give feedback.
All reactions