What is the correct way to add bootstrap to a symfony app?

后端 未结 6 614
灰色年华
灰色年华 2021-02-13 13:48

I\'m using symfony framework 3 to develop a web application. I need to add boostrap\'s functionality to my application. I installed bootstrap using the below command. (I\'m usin

6条回答
  •  夕颜
    夕颜 (楼主)
    2021-02-13 14:24

    As an alternative solution, the symlinks could be created automatically upon packages update. For example, in composer.json add new command in "post-update-cmd":

    // ...
    "scripts": {
            "post-install-cmd": [
                "@symfony-scripts"
            ],
            "post-update-cmd": [
                "@symfony-scripts",
                "rm web/bootstrap && ln -s -r `pwd`/vendor/twbs/bootstrap/dist/ web/bootstrap"
            ]
        },
    

提交回复
热议问题