Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

anon90444's avatar

Remove default bootstrap 4 scaffold

Good morning,

I am trying to run the below command within my project directory:

php artisan preset none

The command returns and error:

Command "preset" is not defined.

I am using Laravel 7 is anyone else experiencing or has experienced this issue and have a solution for me?

0 likes
6 replies
anon90444's avatar

Hi @sergiu17,

Thank you for your response my package.json has bootstrap and I have run composer require laravel/ui when I created the project please see below:

package.json

...
"devDependencies": {
        "axios": "^0.19",
        "bootstrap": "^4.0.0",
        "cross-env": "^7.0",
        "jquery": "^3.2",
        "laravel-mix": "^5.0.1",
        "lodash": "^4.17.13",
        "popper.js": "^1.12",
        "resolve-url-loader": "^3.1.0",
        "sass": "^1.15.2",
        "sass-loader": "^8.0.0",
        "vue-template-compiler": "^2.6.11"
    }
...

composor.json

...
"require": {
        "php": "^7.2.5",
        "fideloper/proxy": "^4.2",
        "fruitcake/laravel-cors": "^1.0",
        "guzzlehttp/guzzle": "^6.3",
        "laravel/framework": "^7.0",
        "laravel/tinker": "^2.0",
        "laravel/ui": "^2.0"
    },
...
Sergiu17's avatar

Ohh sorry, there's php artisan ui (vue, react, bootstrap) - I guess you have manually remove bootstrap from package.json file, or run npm remove bootstrap

anon90444's avatar

Thanks @sergiu17.

Do I need to physically delete any files and if so do know which files should be altered or removed or running npm uninstall bootstrap will refactor my project for me?

anon90444's avatar

For interest sake I ran that command and removed bootstrap but the files still linger do you perhaps know which files should be altered or deleted?

Sergiu17's avatar
Sergiu17
Best Answer
Level 60

npm uninstall bootstrap will refactor my project for me?

No, if you have code which depends on bootstrap, then you have to adjust your code, and only after run npm remove bootstrap

Do I need to physically delete any files

No, npm remove bootstrap will remove everything from node_modules folder

anon90444's avatar

Thank you @sergiu17 and besides the node_modules of course the bootstrap related scripts with resources and public should be deleted.

1 like

Please or to participate in this conversation.