Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Feature request: configurable base feature & job class #9

sasokovacic started this conversation in Ideas
Discussion options

Hi, it would be really nice to be able to set a default base feature and job classes in the config file.
Right now when you generate a new feature, it extends the Lucid\Foundation\Feature and when you generate a new job class it extends the Lucid\Foundation\Job class.
In my case, I have a base feature class that extends Lucid\Foundation\Feature and every new feature extends my base class because of some common functionalities. The same applies to job classes. The problem I have is it's very annoying to manually set base class every time I generate a new feature of job class.

You can also suggest a different approach on how to handle this challenge if there is one.

You must be logged in to vote

Replies: 2 comments 1 reply

Comment options

Interesting suggestion!

Would something like lucid make:feature MyFeature --base=App\Features\BaseFeature work for you? I'm considering adding this to get you rid of this inconvenience.

You must be logged in to vote
0 replies
Comment options

this is better than putting in manually, but it would be even better if make:feature command would get the base class from the config file. Usually, you don't want to have many different base classes so it would be more practical to set it only once and then forget about it, or else you would have to write the full namespace every time you would make a new feature or job.

You must be logged in to vote
1 reply
Comment options

Love this idea and it's been added to the roadmap 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Ideas
Labels
None yet
Converted from issue

This discussion was converted from issue #9 on December 10, 2020 21:58.

AltStyle によって変換されたページ (->オリジナル) /