Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

don't know. But the smart folk behind should be able to figure something out.


Just auto-filling all <p>'s and <h_>'s might be an interesting option. You could also have the API allow you to list tag names to be auto-filled. It can even be smart and first check whether the tag in question already contains text content, and if it doesn't, only then auto-fill it.


Nice suggestion. I made some modifications so this is the new behavior. Child elements are targeted, and content is never overwritten.

``` <div class="fixie"> <p></p> <p>Hello <a></a></p> </div> ``` The above will cause only the first `<p>` tag to be filled, and the `<a>` tag.

In addition, you can now use `fixie.init(["CSS-selector"]);` to target arbitrary tag names, class names, and ids. If the tag in question contains text content, it will not auto-fill it (though it will auto-fill children, if need be).


I considered doing that, but the problem is that I've noticed that some people use <p> tags as breaks between paragraphs. Requiring a class makes sure that the developer/designer knows where their filler content is going.


If you're going to require classnames anyway, it might be more flexible to use those to define the type of content to insert. Personally I'd prefer adding a simple bit of js to a page to define the fixie behaviour, something like :

  fixie.fill('.my_header_class','head');
  fixie.fill('#my_id','paragraphs');

etc, as otherwise I have to have a special layout with lots of 'fixie' everywhere and perhaps a special structure using certain tags in order to use the js, and can't define what sort of content goes where except by changing the type of html element which contains it.

I'd prefer to start with an html document which has already been made, and consider how to add fixie to it in the least obtrusive way - and how to remove it later when it was not required, without impacting the document structure or classes etc at all. So if I can add a bit of js which adds fixie in an unobtrusive way to any existing page, and then remove it by simply commenting out that js, that would be preferable to having to set up a special template just to use fixie, or having to consider fixie use from the start. Fixie should really IMHO adapt to the html it is used on, not force that html to be adapted to it.


As mentioned elsewhere, this is now implemented as `fixie.init(["CSS-selectors"]);`


yep, we added fixie.init(query); functionality. coming up soon.




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: