rrousselGit / functional_widget

A code generator to write widgets as function without loosing the benefits of classes.
597 stars 46 forks source link

Support hiding the "raw" functions #42

Closed derolf closed 2 years ago

derolf commented 5 years ago

It would be nice to decorate _example and generate Example so that users don't refer to _example by accident.

rrousselGit commented 5 years ago

You mean to write a private function and it'd generate a public class?

derolf commented 5 years ago

Exactly.

rrousselGit commented 5 years ago

It's an interesting idea. But then, how would peoples generate private classes?

derolf commented 5 years ago

With two underscores 😂

derolf commented 5 years ago

What about making it an option you can pass? (Remove leading underscore)

Sent with GitHawk

rrousselGit commented 2 years ago

The generated class name is now the function name, with the first _ removed

So:

This should cover this use-case