Search

Ideas that are…

Search Ideas


1806 ideas match your query.:

Done as of c11a13c.

#354​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

As of 9702c05, a revision activity now says that the idea was either marked or unmarked as a criticism.

#353​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

Done as of 735c3cc.

#352​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

such like

‘just like’

#348​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

Done as of 8269806.

#347​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

Done as of 7e7c6cd.

#346​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

Done as of 146e967.

#343​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

It doesn’t really matter. This would be like calling a controller action from a helper method. Not something people do.

#341​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

I think the thing I’m really fighting here is Rails being object-oriented. Which I can’t do anything about.

Not sure the Rails team realizes how much OOP reduces the extensibility of Rails.

#335​·​Dennis HackethalOP revised about 2 years ago​·​Original #334​·​Archived

Having explored three different ideas, I believe #302 – having regular helper methods to render Hiccdown structures – is the best.

The idea is not without its flaws, but having to qualify a method name by, say, calling it idea_form instead of form is still better than manually having to pass the view context around all the time and not being able to trivially access instance variables.

So I’ll stick with #302 for now, which is the status quo already.

#333​·​Dennis HackethalOP, about 2 years ago​·​Archived

#327 applies here, too: no access to instance variables inside helper class methods.

#332​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

That’s way too verbose.

#329​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

Instance variables are not available inside the methods.

#327​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

I’m trying this now. Having to prepend every invocation of a helper method with vc. is getting really old really fast.

#326​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

Tested, it works. self does indeed point to the view_context in the helper. Verified by printing object_ids.

#323​·​Dennis HackethalOP revised about 2 years ago​·​Original #322​·​CriticismArchived

Maybe ‘Display’. ProductsDisplay

#320​·​Dennis HackethalOP, about 2 years ago​·​Archived

I don’t like the term ‘renderer’ yet. It’s too loaded with meaning, what with Rails already having a render method in controllers and another render method in views…

#319​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

I don’t think that’s something people would do a lot, but they still easily could: ProductsRenderer.index(self)

#315​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

Hiccdown methods should live in their own, separate modules. How about they are called ‘renderers’?

ruby
module ProductsRenderer
def self.index vc, # …
vc.some_helper_method
end
end
#313​·​Dennis HackethalOP, about 2 years ago​·​Archived

That would be mixing class methods an instance methods in Rails helper modules, which typically only contain instance methods. Not idiomatic Rails usage.

#312​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

If so, there might be a way to bind them to the view_context. Or I could definitely pass the view_context explicitly as the first parameter:

So instead of

ruby
@helper_module.instance_method(@action_name).bind_call(view_context)

I would do

ruby
@helper_module.send(@action_name, view_context)

And the parameter list of each Hiccdown method would start accordingly:

ruby
module ProductsHelper
def self.index vc #, …
vc.some_helper_method
end
def some_helper_method
# …
end
end
#310​·​Dennis HackethalOP revised about 2 years ago​·​Original #307​·​CriticismArchived

That isn’t a good idea because Hiccdown methods often share the same conventional names (index, show, etc), which can and does lead to conflict.

#301​·​Dennis HackethalOP, about 2 years ago​·​CriticismArchived

Clearly, a fetus without a nervous system can’t be sentient and thus can’t be a person, right?

It’s not considered a fetus until week 9, at which point the nervous system has already begun building.

The correct word to use here is ‘embryo’.

#298​·​Dennis HackethalOP, about 2 years ago​·​Criticism

If an already-born person is deadly ill, that doesn’t mean you can kill them. Why should that be any different for an unborn person?

#279​·​Dennis HackethalOP revised about 2 years ago​·​Original #278​·​Criticism

What happens if only one of two twins is non-viable but abortion would kill both?

#277​·​Dennis HackethalOP, about 2 years ago​·​Criticism