[twdev] What happened to twFile?

411 views
Skip to first unread message

John Kim Murphy

unread,
May 2, 2010, 6:32:21 AM5/2/10
to tiddly...@googlegroups.com

Hello,

 

I was creating a Single Page Application(SPA) using twFile.

However, it seems the jQuery plugin was folded back into the TiddlyWiki code.

Does anyone know why?

 

The latest version of twFile does not work well in IE.

I think the newer TiddlyWiki code will work.

I am thinking about just extracting the bits I need.

Otherwise, does anyone have a better suggestion for creating an SPA?

 

If there is interest, I could revive the jQuery.twFile plugin.

 

Thank you,

John

--
You received this message because you are subscribed to the Google Groups "TiddlyWikiDev" group.
To post to this group, send email to tiddly...@googlegroups.com.
To unsubscribe from this group, send email to tiddlywikide...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/tiddlywikidev?hl=en.

FND

unread,
May 2, 2010, 7:48:43 AM5/2/10
to tiddly...@googlegroups.com
> I was creating a Single Page Application (SPA) using twFile

Excellent!

> However, it seems the jQuery plugin was folded back into the TiddlyWiki
> code <http://trac.tiddlywiki.org/changeset/10178>.
> Does anyone know why?

Unfortunately, this was necessary to retain backwards compatibility
without compromising the stand-alone plugin:
http://trac.tiddlywiki.org/ticket/1113
http://trac.tiddlywiki.org/changeset/10172

> The latest version of twFile does not work well in IE.

Can you elaborate?

> I think the newer TiddlyWiki code will work.
> I am thinking about just extracting the bits I need.
> [...]
> If there is interest, I could revive the jQuery.twFile plugin.

Any contributions would be most welcome!

> Otherwise, does anyone have a better suggestion for creating an SPA?

Somewhat surprisingly, it appears the SPA concept is not widely
recognized beyond TiddlyWiki - so AFAIK, few hackers have explored
alternative avenues.
FWIW, Mike gave a presentation at JSConf recently:
http://softwareas.com/spa-hacks


-- F.

wonsungi

unread,
May 6, 2010, 7:59:35 AM5/6/10
to TiddlyWikiDev
On May 2, 8:48 pm, FND <F...@gmx.net> wrote:

> > The latest version of twFile does not work well in IE.
>
> Can you elaborate?

Using IE 8.0.7600 and http://jquery.tiddlywiki.org/twFileDemo.html
results in the following error when the edit button is pressed:
[...]
Message: Unexpected call to method or property access.
Line: 60
Char: 2307
Code: 0
URI: file:///C:/Users/John/Desktop/twFileDemo.html

The error is located within the jQuery code. I tried replacing with
jQuery 1.4.2 with similar results.


> > However, it seems the jQuery plugin was folded back into the TiddlyWiki
> > code <http://trac.tiddlywiki.org/changeset/10178>.
> > Does anyone know why?
>
> Unfortunately, this was necessary to retain backwards compatibility
> without compromising the stand-alone plugin:http://trac.tiddlywiki.org/ticket/1113
> http://trac.tiddlywiki.org/changeset/10172

So are both the TiddlyWiki filesystem code and twFile jQuery plugin
being maintained?
I assumed the jQuery plugin was abandoned. They are just so different
now (and the TiddlyWiki filesystem save() still works in IE.)


BTW the SPA I am creating is a todo list task manager. It uses an HTML
table to store a simple database table.

John

FND

unread,
May 7, 2010, 2:42:15 AM5/7/10
to tiddly...@googlegroups.com
> Using IE 8.0.7600 and http://jquery.tiddlywiki.org/twFileDemo.html
> results in the following error when the edit button is pressed: [...]

I'm afraid I don't have IE8 available right now.

> The error is located within the jQuery code. I tried replacing with
> jQuery 1.4.2 with similar results.

Have you tried using the non-minified version to get a better idea of
where things are going awry?

Things are pretty busy at the moment, so I'm not sure when we'll get
around to looking into this. Thus any help debugging this would be very
welcome; identifying the statement triggering this error would be a
great help (once that's identified, the fix might be obvious).

> So are both the TiddlyWiki filesystem code and twFile jQuery plugin
> being maintained?

Well, yes - in theory anyway...
With the advent of TiddlyWiki5, $.twFile will become a primary concern
again, as I'm pretty sure Jeremy will use this modern API.

> BTW the SPA I am creating is a todo list task manager. It uses an HTML
> table to store a simple database table.

Looking forward to seeing what you come up with.


-- F.

bougon

unread,
May 27, 2010, 1:19:15 PM5/27/10
to TiddlyWikiDev
wonsungi,

I had a similar error. The problem was not caused by jQuery itself by
a bad argument that was passed to jQuery from the twDemo. For me, it
was the CSS attribute "marginTop" which is an invalid CSS attribute.
Changing mine to "margin-top" solved my issues.

Hope this helps,

Dan

On May 6, 7:59 am, wonsungi <wonsu...@gmail.com> wrote:
> On May 2, 8:48 pm, FND <F...@gmx.net> wrote:
>

> > > The latest version oftwFiledoes not work well in IE.
>
> > Can you elaborate?
>
> Using IE 8.0.7600 andhttp://jquery.tiddlywiki.org/twFileDemo.html


> results in the following error when the edit button is pressed:
> [...]
> Message: Unexpected call to method or property access.
> Line: 60
> Char: 2307
> Code: 0
> URI: file:///C:/Users/John/Desktop/twFileDemo.html
>
> The error is located within the jQuery code. I tried replacing with
> jQuery 1.4.2 with similar results.
>
> > > However, it seems the jQuery plugin was folded back into the TiddlyWiki
> > > code <http://trac.tiddlywiki.org/changeset/10178>.
> > > Does anyone know why?
>
> > Unfortunately, this was necessary to retain backwards compatibility
> > without compromising the stand-alone plugin:http://trac.tiddlywiki.org/ticket/1113
> >http://trac.tiddlywiki.org/changeset/10172
>

> So are both the TiddlyWiki filesystem code andtwFilejQuery plugin

wonsungi

unread,
Jul 10, 2010, 1:03:00 AM7/10/10
to TiddlyWikiDev
I finally figured it out!

The problem was in the twFileDemo.html file on line 397:
var textarea = $("<textarea></textarea><br>").css({

That "<br>" messes up jQuery's text() method when inserting text
between the opening and closing <textarea> tags.
Removing that "<br>" solves the problem in IE; "marginTop" does not
actually cause problems.

FND

unread,
Jul 10, 2010, 3:02:37 AM7/10/10
to tiddly...@googlegroups.com
> The problem was in the twFileDemo.html file on line 397:
> var textarea = $("<textarea></textarea><br>").css({

Excellent work uncovering that! Should be fixed now.


-- F.

Reply all
Reply to author
Forward
0 new messages