On 22.05.2012 21:27, Gabriel Wicke wrote:
>> So, instead of {{{data}}} there would be {{#data:}}, instead of
>> {{{data.color}}} there would be {{#data:color}}, instead of
>> {{{data.color(ACME_SURVEY_2010)}}} there would be
>> {{#data:color|ref=ACME_SURVEY_2010}} and so on.
> 
> This could even be simplified further to
> 
> {{#data:{{{data_item}}}|color}}
> 
> The syntax is admittedly longer, but would work as-is with alternate
> parsers such as Parsoid or a generic parser function API in Lua. It
> would also preserve referential transparency as far as possible, which
> is good for finer-grained caching.

That's pretty much what I was doing with {{#data-value:data.color}}. Turning
that into {{#data-value:{{{data}}}|color}} would actually be fine, though a bit
ugly. Perhaps it would even be nice to turn it around:
{{#property:color|{{{data}}}}}.

However, I'd still like to support the plain template parameter syntax with
pseudo-parameters, e.g. {{{data.color}}} for retrieving the flat wikitext value
of the property.

Do you think that's ok? Or does it introduce complications with respect to Lua, 
etc?

-- daniel

-- 
Daniel Kinzler, Softwarearchitekt

Wikimedia Deutschland e.V. | Eisenacher Straße 2 | 10777 Berlin
http://wikimedia.de  | Tel. (030) 219 158 260

Wikimedia Deutschland - Gesellschaft zur Förderung Freien Wissens e.V.
Eingetragen im Vereinsregister des Amtsgerichts Berlin-Charlottenburg
unter der Nummer 23855 B. Als gemeinnützig anerkannt durch das Finanzamt
für Körperschaften I Berlin, Steuernummer 27/681/51985.

_______________________________________________
Wikidata-l mailing list
Wikidata-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata-l

Reply via email to