Template talk:JavaScript
Appearance
![]() | This template does not require a rating on Wikipedia's content assessment scale. It is of interest to the following WikiProjects: | |||||||||||||||||||||||||||||||
|
Move proposal on January 9, 2014
![]() | It has been proposed in this section that Template:JavaScript be renamed and moved to Template:JavaScript navbox. A bot will list this discussion on the requested moves current discussions subpage within an hour of this tag being placed. The discussion may be closed 7 days after being opened, if consensus has been reached (see the closing instructions). Please base arguments on article title policy, and keep discussion succinct and civil. Please use {{subst:requested move}} . Do not use {{requested move/dated}} directly. |
Template:JavaScript → Template:JavaScript navbox – To make room for a new Template:JavaScript that can be used as a wrapper for edit requests to .js pages with source highlighting and background coloring. Examples would look like: (moved below my signature for transcluding reasons) Thanks for your consideration Technical 13 (talk) 05:42, 9 January 2014 (UTC) Technical 13 (talk) 05:42, 9 January 2014 (UTC)
Discussion
- Technical 13, would you mind reformatting the nomination so the examples aren't part of the initial statement? It's affecting display at WP:RM. Thanks, BDD (talk) 19:41, 9 January 2014 (UTC)
- Examples: (moved from above)
This would...
{{JavaScript|remove|
/* section */
var section = true;
if(!section){
alert("LIES!");
}
}}
...result in:
/* section */
var section = true;
if(!section){
alert("LIES!");
}
or
This would...
{{JavaScript|add|
/* section */
var section = true;
if(section){
alert("You've spoken the truth!");
}
}}
...result in:
/* section */
var section = true;
if(section){
alert("You've spoken the truth!");
}
Survey
Support
- As nominator - Technical 13 (talk) 05:43, 9 January 2014 (UTC)
Oppose
- Oppose; I think the unadorned name should remain a topic navbox. Powers T 13:19, 9 January 2014 (UTC)
Support/Oppose
- Support the move of this template. Oppose the proposed reuse of this name. It should be "{{edit javascript}}" instead, just like {{edit request}} , {{edit protected}} , {{edit semiprotected}}. It should NOT BE {{JavaScript}} or {{javascript}} ; a more beneficial use of this template location would be a formatting template that uses LUA to format JS code samples. -- 70.50.148.122 (talk) 06:57, 9 January 2014 (UTC)
- It's not an edit request itself (which would still use the main {{Edit protected}} because only admins can edit .js pages (excluding your own in your userspace, but you would need to submit a request for that_). My proposed replacement is a formating template that uses mw:Extension:SyntaxHighlight GeSHi to format JS code samples. Any formating template that uses Lua to format JS code samples would be located at Module:JavaScript. Technical 13 (talk) 07:08, 9 January 2014 (UTC)
- Thanks for the clarification. Your nomination rationale makes it look like creating an edit request template. Making {{JavaScript}} a JS formatting template is a good idea. However, the green/red option seems mandatory, this should not be the case, if it is to provide generic javascript formatting functionality. Can it just be plain clear if it doesn't specify add or remove? -- 70.50.148.122 (talk) 08:16, 9 January 2014 (UTC)
{{JavaScript|
/* section */
var section = true;
if(!section){
alert("TEXTALERT");
}
}}
/* section */
var section = true;
if(!section){
alert("TEXTALERT");
}
- If
|1=
is not add or remove (or one of any other predefined words), then yes is could be neutral and use the gray color (or no color or any other neutral color like yellow). Technical 13 (talk) 14:57, 9 January 2014 (UTC)
- If
- Wait, I thought this was a navbox. Are we talking about the move of that navbox, or a protected template edit request? Epicgenius (talk) 19:03, 9 January 2014 (UTC)
- Epicgenius, we're talking about moving the navbox to Template:JavaScript navbox to make room for a new formatting template that would be more appropriate at this page name. Technical 13 (talk) 19:27, 9 January 2014 (UTC)
- Thanks. So it's a move discussion after all. In any case, I don't think a rename is needed yet. Epicgenius (talk) 13:52, 10 January 2014 (UTC)
- I am unclear why a new template's needed. It can be done with the syntaxhighlight tag, as seen in the examples above. Though the background colours are unhelpful I think for syntax highlighted code, which makes the tag even simpler. Perhaps the proposer can point to some discussions where formatted code with brightly coloured backgrounds might have been useful. But even given all that there's nothing stopping you creating a template now, and calling it something else. Then if it gets heavily used and becomes common then there might be a case for it taking the name of this one. Until then oppose.--JohnBlackburnewordsdeeds 22:03, 9 January 2014 (UTC)