Welcome Guest, Not a member yet? Register   Sign In
What is best practice to modify Vendor views?
#1

Let say I set new CI4 instance, then put Shield (Auth) with composer which reside under Vendor folder.
CI4 will autoload Shield including all "Pre-made" views (login+forgot password+register+etc)
So how to move Views for our main project instead "Vendor's belonging?, because if we modify those Views under Vendor, then it all will be replaced whenever we do Composer Update.
Reply
#2

Views are defined in the config.
Or is this not what you need?
Reply
#3

(01-06-2023, 10:17 PM)iRedds Wrote: Views are defined in the config.
Or is this not what you need?

If I did modified all Config\* configuration, then if I do Composer Update then will the Config\* files remain or replaced?
Reply
#4

(This post was last modified: 01-07-2023, 04:26 AM by datamweb.)

Hi @munggaran,

Command

Code:
php spark shield:setup

creates a new file for this topic in path app/Config/Auth.php.

Therefore, if you update with Composer, there will be no problem until you execute command

Code:
php spark shield:setup

again.

We have clearly explained this issue in the Manual Setup guide of the first(1) paragraph.

Refer to How to define custom views.

Meanwhile, I plan to add a CLI command to set the views via the command line to the shield in [email=https://github.com/codeigniter4/shield/pull/489]PR#489[/email], which has not been done yet.

So feel free to make your settings in file app/Config/Auth.php.
Reply
#5

(01-07-2023, 04:21 AM)datamweb Wrote: Hi @munggaran,

Command

Code:
php spark shield:setup

creates a new file for this topic in path app/Config/Auth.php.

Therefore, if you update with Composer, there will be no problem until you execute command

Code:
php spark shield:setup

again.

We have clearly explained this issue in the Manual Setup guide of the first(1) paragraph.

Refer to How to define custom views.

Meanwhile, I plan to add a CLI command to set the views via the command line to the shield in [email=https://github.com/codeigniter4/shield/pull/489]PR#489[/email], which has not been done yet.

So feel free to make your settings in file app/Config/Auth.php.

AHA!, this is what I'm looking for, need to get more intimate with manuals, thanksss
Reply




Theme © iAndrew 2016 - Forum software by © MyBB