Questions tagged [content-tag]

Use this tag to ask questions related to HTML5 content element. It is used inside shadow DOM to insert distributed nodes.

The HTML <content> element is used inside of Shadow DOM as an insertion point. It is supposed to be used with Web Components.

<content> tag can be placed inside shadow DOM which specifies where to distribute light DOM placed inside host element.

It also supports a select attribute which can be used to selectively pick and distribute certain nodes.

50 questions
15
votes
3 answers

Is that possible to call method that uses "content_tag" from controller in Rails 3?

In my Rails 3 application I use Ajax to get a formatted HTML: $.get("/my/load_page?page=5", function(data) { alert(data); }); class MyController < ApplicationController def load_page render :js => get_page(params[:page].to_i) …
Misha Moroshko
  • 166,356
  • 226
  • 505
  • 746
11
votes
4 answers

rails 3 link_to with nested content_tag to create

Hi I got a noob question, I want to create the following HTML result: TEXT In the above HTML I want to have text with a span-class to style in an image via…
user1260945
  • 111
  • 1
  • 1
  • 3
7
votes
2 answers

Rails 3.2 using content_tag to generate a 'Delete' button with twitter-bootstrap icons

I'm trying to replicate the Delete button icon in this example using the Rails 3 content_tag method, within a nested form and using jQuery unobtrusively (or at least I hope to be). Twitter-Bootstrap Delete Button icon (example) The html produced in…
rails3dev
  • 96
  • 1
  • 1
  • 4
5
votes
2 answers

Polymer: How to watch for change in properties

I'm just starting to learn Polymer. Here is a generic version of my polymer element: