[whatwg] XML data islands related question

Ian Hickson ian at hixie.ch
Tue Aug 6 07:45:22 PDT 2013


On Tue, 6 Aug 2013, Jukka K. Korpela wrote:
> 2013-08-06 2:27, Ian Hickson wrote:
> > On Thu, 7 Feb 2013, Jukka K. Korpela wrote:
> [...]
> > > It's a bit odd that if you wish to set up a standalone application 
> > > running in a browser (often called "HTML5 application", without 
> > > implying any particular version of HTML5), you can include e.g. 
> > > scripts and images in separate files but not plain text or XML data
> > 
> > Why can't you put plain text or XML data in other files? So long as 
> > everything is same origin, you can read anything you want via XHR.
> 
> A standalone application should be as self-contained as possible, 
> without needing HTTP connections or any network connections to access 
> its own data. When no connections are needed for other reasons, an HTML5 
> application should run in any client capable of just interpreting HTML 
> and JavaScript (and, in practice, CSS).
> 
> If such an application needs some bulk of text data, it can be included 
> e.g. in <script type=text/plain>...</script> but not in a separate plain 
> text file (included into the application distribution, along with other 
> files) referred to via <script src=...></script>. This is a frustrating 
> restriction and makes it more difficult to maintain and customize 
> application. If an external plain text file could be used, the data 
> content could be separately managed (requiring knowledge only about the 
> format used).

I'm not sure what you mean by "application distribution". Why can't a 
text/plain file by included the same way an image/png file is included?

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'



More information about the whatwg mailing list