@TW Tones, the method I employed is actually quite simple, it's powered by 
a repository in my Github, using Github pages. I figured that this meant it 
had to call the index.html (the html file holding tiddlyWiki) file to 
display my tiddlyWiki. However, I took this a few steps further by making 
it sync back to that same github index.html file. Basically, this means 
that it places a call through the Github API, which is modified every time 
the users save it. Lastly, my most buggy area, (which you have seen) is 
making it work cross-platform. I happened to stumble upon the localStorage 
value for the Github PAT while digging through the console values to figure 
out a simple error, and realized that I could just add a 
localStorage.setItem call to add the value to any computer that opens the 
page, meaning they have the same functionality as me. Of course, this means 
that the application is not so secure, as anyone can grab the Github PAT 
from the console with one line of javascript, but I have a few methods in 
place to prevent/protect myself in the case that this happens.

On Saturday, January 23, 2021 at 9:35:24 AM UTC-5 Finn Lancaster wrote:

> Whoops! Thanks for the quick bug catch! My raw tagged tiddler must have 
> been accidentally deleted when I was screwing with the Shadow Tiddlers. I 
> just fixed it now and tested, seems to be fine except for the usual edit, 
> save, refresh, then repeat to actually show up. Also, it's been throwing a 
> 409 error when saved on chrome especially, but the changes still seem to 
> sync.
>
> On Saturday, January 23, 2021 at 12:39:46 AM UTC-5 TW Tones wrote:
>
>> I had a look, when I try and save it just uses the default save HTML to 
>> file.
>>
>> Could you include more instructions on collaboration and the method you 
>> have employed please?
>>
>> Tones
>>
>> On Saturday, 23 January 2021 at 01:11:58 UTC+11 flanc...@gmail.com wrote:
>>
>>> Amazing! My collab idea works perfectly. Check it out at 
>>> wiki.finnsoftware.net. Just a warning, for changes to upload, you must 
>>> make the change, save, refresh, and then redo it, which can get quite 
>>> annoying. After the second refresh as described though, the change will be 
>>> shown.
>>>
>>> On Thursday, January 21, 2021 at 10:56:46 PM UTC-5 TW Tones wrote:
>>>
>>>> Search for raw on tiddlywiki.com and each of the special system tags 
>>>> will be listed. 
>>>>
>>>> If you have a tiddler containing the information you want choose the 
>>>> appropriate tag and tag the tiddler, and it will be saved into the 
>>>> specific 
>>>> location such as in the head element. Each system tag explains where it 
>>>> will be stored.
>>>>
>>>> I am not sure if the script will fire as you expect, but its worth a 
>>>> try.
>>>>
>>>> As a newby, from an experienced user (not Plugin developer yet), in 
>>>> plain English as I understand it, TiddlyWikis automatic links and magic 
>>>> comes from the fact that it has its own framework. Plugin Javascript needs 
>>>> to comply with various standards to maintain the magic in tiddlywiki. 
>>>> TiddlyWiki is also structured in a way people cant inject Javascript with 
>>>> out the ability to save and reload the wiki which is an essential security 
>>>> feature.
>>>>
>>>> Also;
>>>>
>>>> There is a local storage plugin and also password widget in tiddlywiki. 
>>>> I recommend always checking if tiddlywiki has already provided a 
>>>> mechaisium 
>>>> for what ever you want to do before going off on your own, many things 
>>>> have 
>>>> being already included such that javascript is unnecessary.
>>>>
>>>> Tones
>>>>
>>>> On Friday, 22 January 2021 at 12:43:48 UTC+11 flanc...@gmail.com wrote:
>>>>
>>>>> Also, since I am a bit of a newbie to TiddlyWiki, I would be grateful 
>>>>> if you could explain/define RAW tags on tiddlers, and how to use them. 
>>>>> For 
>>>>> example, if I wanted to add a javaScript alert (ie <script>alert('this is 
>>>>> an alert')</script>) that fired on page load, how would I do it with 
>>>>> these 
>>>>> RAW tags?
>>>>>
>>>>> On Thursday, January 21, 2021 at 8:41:12 PM UTC-5 Finn Lancaster wrote:
>>>>>
>>>>>> Sure @TW Tones. I'm adding the following lines to the HTML file: 
>>>>>> <script>localStorage.setItem('tw5-password-github','GITHUB 
>>>>>> PAT');</script>. 
>>>>>> I have added them to various places, both inside and outside the DOM (ie 
>>>>>> <head>, <body>, before and after </html>). This works perfectly by 
>>>>>> displaying the localStorage value when I type localStorage in console. 
>>>>>> When 
>>>>>> I edit some stuff and then save it to github, when I go back the 
>>>>>> localStorage will be cleared. On Github, the message "Saved by 
>>>>>> TiddlyWiki" 
>>>>>> is shown under commits, and the raw source code does not show the 
>>>>>> modified 
>>>>>> localStorage attributes.
>>>>>>
>>>>>> On Thursday, January 21, 2021 at 8:21:19 PM UTC-5 TW Tones wrote:
>>>>>>
>>>>>>> I think you need to describe this with a little more details.
>>>>>>>
>>>>>>> The tiddlywiki save process saves the html according to a template 
>>>>>>> and filters, if you alter the html file by other means it may not 
>>>>>>> matter 
>>>>>>> when it goes to save, it will save as it is setup to.
>>>>>>>
>>>>>>> Perhaps if you explain what if anything, you are changing in the 
>>>>>>> html file
>>>>>>> It is common to introduce other code to the tiddlywiki using 
>>>>>>> additional RAW tags on tiddlers.
>>>>>>>
>>>>>>> Tones
>>>>>>>
>>>>>>> On Friday, 22 January 2021 at 12:00:13 UTC+11 flanc...@gmail.com 
>>>>>>> wrote:
>>>>>>>
>>>>>>>> Hi all,
>>>>>>>> As some of you know, I have been working on a TiddlyWiki 
>>>>>>>> Collaboration script. Basically, the script works by being hosted from 
>>>>>>>> Github Pages, and calling the file straight from github to display, 
>>>>>>>> showing 
>>>>>>>> each of the recent changes. This main described functionality works 
>>>>>>>> perfectly, except that, when saved to github, the index.html file 
>>>>>>>> storing 
>>>>>>>> tiddlywiki is deleted and remade with the changes, meaning that any 
>>>>>>>> additional html I have added onto the file for the collab to work is 
>>>>>>>> gone. 
>>>>>>>> In short, this breaks it after the first use, and I'm stuck on what to 
>>>>>>>> do.
>>>>>>>>
>>>>>>>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/e7e2c3dc-35bc-4a9b-beb1-3bcbdaa4d780n%40googlegroups.com.

Reply via email to