activeadmin影响前端样式的解决方法
source link: http://blog.ilibrary.me/2019/08/01/activeadmin%E5%BD%B1%E5%93%8D%E5%89%8D%E7%AB%AF%E6%A0%B7%E5%BC%8F%E7%9A%84%E8%A7%A3%E5%86%B3%E6%96%B9%E6%B3%95
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
ActiveAdmin是一个非常好用的web后台管理gem,功能丰富,灵活多变。
但是,它的样式默认会影响前端页面。
这个问题在每个用activeadmin的新项目中都会遇到,所以记录下来供后面参考。
stackoverflow上面提供了一个方法
- 首先在vendor/目录下创建assets目录
- 在vendor/assets目录下创建两个子目录, stytlesheets和javascripts
- 把assets/stylesheets/active_admin.css 移动到vendor/assets/stylesheets/active_admin.css
- 把assets/javascripts/active_admin.js.coffee移动到vendor/assets/javascripts目录下面去
- 重启rails server, 问题解决.
Recommend
-
14
Published on 10 September 2020 in rails Adding Two-Factor Authentication(2FA) to ActiveAdmin auth in a Ruby on Rails web application To enhance the...
-
8
Active Admin Gem Tips and Performance Tuning for Rails Apps Updated Jun 28, 2019 11 comments 6 minute read
-
3
activeadmin无出错提示 | 垂钓江湖 欢迎转载,请支持原创,保留原文链接:blog.ilibrary.me
-
5
前端 + AI ——从图片识别UI样式腾讯科技有限公司 高级工程师导语:前端智能化,就是通过AI/CV技术,使前端工具链具备理解能力,进而辅助开发提升研发效率,比如实现基于设计稿智...
-
7
Use ActiveAdmin like a bossHi, weʼre arkency 👋 ActiveAdmin is widely used administration framework in Rails applications. This post explains how to hook more sophiscicat...
-
5
小高不太行之前端——CSS样式(基础)上 提示:下篇马上问世,在赶了在赶了 浪了n周以后那个小高又回来了,要对CSS下手了,走过路过留下小心心哦Cascading Style
-
6
一文了解react中定义样式(css/less/sass)的常用方法发布于 今天 12:55 react中通过jsx的语法方式,将html标签和js语法联系在一起,而css的编写方式,没有明确的指定编写方式,...
-
3
HTML中要实现某一内容水平居中显示,要通过设置css样式来实现,主要分为行内元素和块状元素两种情况,块状元素又可分为块状定宽与块状不定宽两种情况,接下来依次介绍分...
-
9
activeadmin后台filter性能问题 | 代码魔改师 欢迎转载,请支持原创,保留原文
-
5
解决Cloudflare显示524错误WordPress后台CSS样式无法加载 https://www.chenweiliang.com/cwl-28604.html
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK