douke1905 2019-01-17 11:36
浏览 48

如何使用我的标准Laravel项目正确设置MDBootstrap

I am in the process of learning how to use Laravel and I am interested in styling my web pages using MDBootstrap. However, I am confused about how to integrate it into my project correctly. I do not want to link it using CDN, instead I would like to install it into my project.

Can someone show me the necessary steps to achieve this in a basic Laravel project?

  • 写回答

1条回答 默认 最新

  • douchengchu8374 2019-01-17 12:03
    关注

    Laravel comes with 2 frontend package managers: npm and yarn

    npm

    npm i mdbootstrap
    

    yarn

    yarn add mdbootstrap
    

    After this your package is located in the node_modules directory.

    You can import sass files and let the js be combined from packages to vendor.js.

    You can configure what gets transpiled to where using webpack.mix.js

    Running npm run dev will start the transpiling.


    If you want to install mdbootstrap pro, you should follow these steps

    1. get a license and mail contact@mdbootstrap.com requesting access to their git repo (as they have not automated this)
    2. generate an access token on gitlab
    3. run

      npm install git+https://oauth2:[TOKEN]@git.mdbootstrap.com/mdb/[REPO].git --save
      

      Where [TOKEN] is your token from step 2 and [REPO] is the one you need from the choices jquery, angular, vue or react. You can find the exact urls by visiting git.mdbootstrap.com and choosing the right project. In the top right corner find the clone button and copy the https link.

    评论

报告相同问题?

悬赏问题

  • ¥50 如何用脚本实现输入法的热键设置
  • ¥20 我想使用一些网络协议或者部分协议也行,主要想实现类似于traceroute的一定步长内的路由拓扑功能
  • ¥30 深度学习,前后端连接
  • ¥15 孟德尔随机化结果不一致
  • ¥15 apm2.8飞控罗盘bad health,加速度计校准失败
  • ¥15 求解O-S方程的特征值问题给出边界层布拉休斯平行流的中性曲线
  • ¥15 谁有desed数据集呀
  • ¥20 手写数字识别运行c仿真时,程序报错错误代码sim211-100
  • ¥15 关于#hadoop#的问题
  • ¥15 (标签-Python|关键词-socket)