uniapp使用scss仿tailwindcss进行常用样式封装便捷开发小程序或web

本文主要是介绍uniapp使用scss仿tailwindcss进行常用样式封装便捷开发小程序或web,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

小程序版本

如果你开发的是小程序的话,或者包含小程序,就只能选这个版本,如果不包含小程序,更推荐使用H5版本

// 文字粗细
$font-weights: (thin: 100,extra-light: 200,light: 300,regular: 400,medium: 500,semi-bold: 600,bold: 700,extra-bold: 800,black: 900
);// 文字大小
@for $i from 8 through 25 {.font-#{$i} {font-size: #{$i}px;}
}@each  $name, $weight in $font-weights {.font-#{$name} {font-weight: $weight;}
}$aligns: (left,center,right,justify
);// 文字位置
@each $align in $aligns {.text-#{$align} {text-align: $align;}
}// 颜色
$colors: (red: #ff0000,darkRed: #d90209,green: #00ff00,blue: #0000ff,black: #000000,white: #ffffff,gray: #808080,lightGray: #e6e6e6,orange: #ffA500,yellow: #ffff00,pink: #ff69b4,purple: #800080, brown: #a52a2a,cyan: #00ffff,lime: #00ff00,navy: #000080,olive: #808000,khaki: #f0e68c,salmon: #fa8072,coral: #ff7f50,gold: #ffd700,lavender: #e6e6fa,turquoise: #40e0d0,peach: #ffdab9,orchid: #da70d6,crimson: #dc143c,forestGreen: #228b22,sienna: #a0522d,sirocco: #736f6e,caputMortuum: #592720,zomp: #39a78e,paleTurquoise: #afeeee,lightSeaGreen: #20b2aa,dodgerBlue: #1e90ff,mediumSlateBlue: #7b68ee,blueViolet: #8a2be2,mediumOrchid: #ba55d3,thistle: #d8bfd8,deepPink: #ff1493,hotPink: #ff69b4,darkSlateGray: #2f4f4f,dimGray: #696969,slateBlue: #6a5acd,mediumBlue: #0000cd,cadetBlue: #5f9ea0,mediumAquamarine: #66cdaa,darkSeaGreen: #8fbc8f,lightGreen: #90ee90,springGreen: #00ff7f,chartreuse: #7fff00,mediumSpringGreen: #00fa9a,paleGoldenrod: #eee8aa,goldenrod: #daa520,sandyBrown: #f4a460,peru: #cd853f,rosyBrown: #bc8f8f,wheat: #f5deb3,darkOrange: #ff8c00,
);// 文字颜色
@each $name, $color in $colors {.text-#{$name} {color: $color;}
}// 布局
// Flex容器样式
.flex {display: flex;
}// 设置主轴方向
.flex-row {flex-direction: row;
}.flex-row-reverse {flex-direction: row-reverse;
}.flex-col {flex-direction: column;
}.flex-col-reverse {flex-direction: column-reverse;
}.flex-center {display: flex;justify-content: center;align-items: center;
}// 垂直居中
.vertical-center {display: flex;align-items: center; // 垂直居中
}// 水平居中
.horizontal-center {display: flex;justify-content: center; // 水平居中
}// 设置主轴对齐方式
.justify-start {justify-content: flex-start;
}.justify-end {justify-content: flex-end;
}.justify-center {justify-content: center;
}.justify-between {justify-content: space-between;
}.justify-around {justify-content: space-around;
}// 设置交叉轴对齐方式
.items-start {align-items: flex-start;
}.items-end {align-items: flex-end;
}.items-center {align-items: center;
}.items-baseline {align-items: baseline;
}.items-stretch {align-items: stretch;
}.items-spaceAround {align-items: space-around;
}.items-spaceBetween {align-items: space-between;
}// 设置子项在交叉轴上的对齐方式
.align-self-auto {align-self: auto;
}.align-self-flex-start {align-self: flex-start;
}.align-self-flex-end {align-self: flex-end;
}.align-self-center {align-self: center;
}.align-self-baseline {align-self: baseline;
}.align-self-stretch {align-self: stretch;
}// 设置子项的排序
.order-1 {order: 1;
}.order-2 {order: 2;
}.order-3 {order: 3;
}// 设置子项的伸缩比例
.flex-grow-1 {flex-grow: 1;
}.flex-grow-2 {flex-grow: 2;
}.flex-grow-3 {flex-grow: 3;
}// 设置子项的初始尺寸
.flex-shrink-1 {flex-shrink: 1;
}.flex-shrink-2 {flex-shrink: 2;
}.flex-shrink-3 {flex-shrink: 3;
}// 设置子项的伸缩基准
.flex-basis-auto {flex-basis: auto;
}.flex-basis-fill {flex-basis: fill;
}.flex-basis-content {flex-basis: content;
}.flex-basis-percent {flex-basis: 50%;
}// margin布局样式
.m-auto {margin: auto;
}.mt-auto {margin-top: auto;
}.mr-auto {margin-right: auto;
}.mb-auto {margin-bottom: auto;
}.ml-auto {margin-left: auto;
}.mx-auto {margin-left: auto;margin-right: auto;
}.my-auto {margin-top: auto;margin-bottom: auto;
}@for $i from -10 through 20 {.margin-#{$i} {margin: #{$i}px;}
}@for $i from -10 through 20 {.mt-#{$i} {margin-top: #{$i}px;}
}@for $i from -10 through 20 {.mr-#{$i} {margin-right: #{$i}px;}
}@for $i from -10 through 20 {.mb-#{$i} {margin-bottom: #{$i}px;}
}@for $i from -10 through 20 {.margin-left-#{$i} {margin-left: #{$i}px;}
}@for $i from -10 through 20 {.my-#{$i} {margin-top: #{$i}px;margin-bottom: #{$i}px;}
}@for $i from -10 through 20 {.mx-#{$i} {margin-right: #{$i}px;margin-left: #{$i}px;}
}// 背景颜色
@each $name, $color in $colors {.bg-#{$name} {background-color: $color;}
}// 宽度
@for $i from 1  through 75 {.w-#{$i * 10} {width: #{$i * 10}rpx;}
}// 宽度-%百分比
@for $i from 1 through 20 {.w-#{$i * 5}P {width: #{$i* 5%};}
}// 屏幕宽度
@for $i from 1 through 20 {.w-#{$i* 5%}vw {width: #{$i* 5%}vw;}
}// 高度
@for $i from 1 through 80 {.h-#{$i * 10} {height: #{$i * 10}rpx;}
}// 高度-%百分比
@for $i from 1 through 20 {.h-#{$i* 5%}P {height: #{$i* 5%};}
}// 屏幕高度
@for $i from 1 through 20 {.h-#{$i* 5%}vh {height: #{$i* 5%}vh;}
}// 内边距
@for $i from 1 through 20 {.p-#{$i} {padding: #{$i}px;}
}// 上内边距
@for $i from 1 through 20 {.pt-#{$i} {padding-top: #{$i}px;}
}// 右内边距
@for $i from 1 through 20 {.pr-#{$i} {padding-right: #{$i}px;}
}// 下内边距
@for $i from 1 through 20 {.pb-#{$i} {padding-bottom: #{$i}px;}
}// 左内边距
@for $i from 1 through 20 {.pl-#{$i} {padding-left: #{$i}px;}
}// 上下内边距
@for $i from 1 through 20 {.py-#{$i} {padding-top: #{$i}px;padding-bottom: #{$i}px;}
}// 左右内边距
@for $i from 1 through 20 {.px-#{$i} {padding-left: #{$i}px;padding-right: #{$i}px;}
}// 圆角
@for $i from 1 through 20 {.radius-#{$i} {border-radius: #{$i}px;}
}// 间隔
// 宽度
@for $i from 1 through 20 {.gap-#{$i} {gap: #{$i}rpx;}
}// 阴影
$shadows: (sm: (0 1px 2px 0 rgba(0, 0, 0, 0.05)),default: (0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1)),md: (0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1)),lg: (0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1)),xl: (0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1)),'2xl': (0 25px 50px -12px rgba(0, 0, 0, 0.25)),inner: (inset 0 2px 4px 0 rgba(0, 0, 0, 0.05)),none: (0 0 rgba(0, 0, 0, 0))
);@each $name, $value in $shadows {.shadow-#{$name} {box-shadow: $value;}
}// 边框
@for $i from 1 through 5 {@each $color-name, $color-value in $colors {.border-#{$i}-#{$color-name} {border: #{$i}px solid $color-value;}}
}@for $i from 1 through 5 {@each $color-name, $color-value in $colors {.border-top-#{$i}-#{$color-name} {border-top: #{$i}px solid $color-value;}.border-right-#{$i}-#{$color-name} {border-right: #{$i}px solid $color-value;}.border-bottom-#{$i}-#{$color-name} {border-bottom: #{$i}px solid $color-value;}.border-left-#{$i}-#{$color-name} {border-left: #{$i}px solid $color-value;}.border-x-#{$i}-#{$color-name} {border-left: #{$i}px solid $color-value;border-right: #{$i}px solid $color-value;}.border-y-#{$i}-#{$color-name} {border-top: #{$i}px solid $color-value;border-bottom: #{$i}px solid $color-value;}}
}// 父元素的1/2 使用方法:father-1_2
@for $i from 2 through 20 {.father-1_#{$i} {width: percentage(1 / $i); // 子元素宽度为父元素的分数}
}// 圆形,直径从5-100
@for $i from 1 through 20 {.circle-#{$i*10} {width: #{$i*10}px;height: #{$i*10}px;border-radius: 50%;}
}// 位于屏幕的最底部位置
.bottom-element {position: fixed;z-index: 1000; // 可以根据实际情况调整 z-indexbottom: 0;left: 0;right: 0;
}// 按钮的基本样式
.btn {transition: background-color 0.3s ease;
}// 按钮的点击后样式
.btn:active {background-color: #ff6600;
}

H5版本

// 文字粗细
$font-weights: (thin: 100,extra-light: 200,light: 300,regular: 400,medium: 500,semi-bold: 600,bold: 700,extra-bold: 800,black: 900
);// 文字大小
@for $i from 8 through 50 {.font-#{$i} {font-size: #{$i}px;}
}@each  $name, $weight in $font-weights {.font-#{$name} {font-weight: $weight;}
}$aligns: (left,center,right,justify
);// 文字位置
@each $align in $aligns {.text-#{$align} {text-align: $align;}
}// 颜色
$colors: (red: #ff0000,darkRed: #d90209,green: #00ff00,blue: #0000ff,black: #000000,white: #ffffff,gray: #808080,lightGray: #e6e6e6,orange: #ffA500,yellow: #ffff00,pink: #ff69b4,purple: #800080, brown13: #a52a2a,cyan14: #00ffff,magenta15: #ff00ff,lime16: #00ff00,teal17: #008080,navy18: #000080,maroon19: #800000,olive20: #808000,beige21: #f5f5dc,ivory22: #fffff0,khaki23: #f0e68c,tan24: #d2b48c,salmon25: #fa8072,coral26: #ff7f50,tomato27: #ff6347,gold28: #ffd700,silver29: #c0c0c0,indigo30: #4b0082,lavender31: #e6e6fa,turquoise32: #40e0d0,violet33: #ee82ee,peach34: #ffdab9,orchid35: #da70d6,skyBlue36: #87ceeb,mintGreen37: #98ff98,crimson38: #dc143c,forestGreen39: #228b22,slateGray40: #708090,sienna41: #a0522d,sirocco42: #736f6e,caputMortuum43: #592720,terraCotta44: #e2725b,redOxide45: #7d4427,zomp46: #39a78e,yellowGreen47: #9acd32,paleGreen48: #98fb98,paleTurquoise49: #afeeee,robinEggBlue50: #00cccc,lightSeaGreen51: #20b2aa,deepSkyBlue52: #00bfff,dodgerBlue53: #1e90ff,steelBlue54: #4682b4,powderBlue55: #b0e0e6,cornflowerBlue56: #6495ed,mediumSlateBlue57: #7b68ee,darkSlateBlue58: #483d8b,blueViolet59: #8a2be2,mediumOrchid60: #ba55d3,darkOrchid61: #9932cc,thistle62: #d8bfd8,plum63: #dda0dd,paleVioletRed64: #db7093,deepPink65: #ff1493,hotPink66: #ff69b4,mediumPurple67: #9370db,darkMagenta68: #8b008b,darkViolet69: #9400d3,darkSlateGray70: #2f4f4f,dimGray71: #696969,slateBlue72: #6a5acd,mediumBlue73: #0000cd,midnightBlue74: #191970,cadetBlue75: #5f9ea0,aquamarine76: #7fffd4,mediumAquamarine77: #66cdaa,darkSeaGreen78: #8fbc8f,lightGreen79: #90ee90,springGreen80: #00ff7f,lawnGreen81: #7cfc00,chartreuse82: #7fff00,mediumSpringGreen83: #00fa9a,paleGoldenrod84: #eee8aa,goldenrod85: #daa520,sandyBrown86: #f4a460,peru87: #cd853f,rosyBrown88: #bc8f8f,wheat89: #f5deb3,tan90: #ffd39b,darkOrange91: #ff8c00,coral92: #ff7256,dodgerBlue93: #FF8C00,
);// 文字颜色
@each $name, $color in $colors {.text-#{$name} {color: $color;}
}// 布局
// Flex容器样式
.flex {display: flex;
}// 设置主轴方向
.flex-row {flex-direction: row;
}.flex-row-reverse {flex-direction: row-reverse;
}.flex-col {flex-direction: column;
}.flex-col-reverse {flex-direction: column-reverse;
}.flex-center {display: flex;justify-content: center;align-items: center;
}// 垂直居中
.vertical-center {display: flex;align-items: center; // 垂直居中
}// 水平居中
.horizontal-center {display: flex;justify-content: center; // 水平居中
}// 设置主轴对齐方式
.justify-start {justify-content: flex-start;
}.justify-end {justify-content: flex-end;
}.justify-center {justify-content: center;
}.justify-between {justify-content: space-between;
}.justify-around {justify-content: space-around;
}// 设置交叉轴对齐方式
.items-start {align-items: flex-start;
}.items-end {align-items: flex-end;
}.items-center {align-items: center;
}.items-baseline {align-items: baseline;
}.items-stretch {align-items: stretch;
}.items-spaceAround {align-items: space-around;
}.items-spaceBetween {align-items: space-between;
}// 设置子项在交叉轴上的对齐方式
.align-self-auto {align-self: auto;
}.align-self-flex-start {align-self: flex-start;
}.align-self-flex-end {align-self: flex-end;
}.align-self-center {align-self: center;
}.align-self-baseline {align-self: baseline;
}.align-self-stretch {align-self: stretch;
}// 设置子项的排序
.order-1 {order: 1;
}.order-2 {order: 2;
}.order-3 {order: 3;
}// 设置子项的伸缩比例
.flex-grow-1 {flex-grow: 1;
}.flex-grow-2 {flex-grow: 2;
}.flex-grow-3 {flex-grow: 3;
}// 设置子项的初始尺寸
.flex-shrink-1 {flex-shrink: 1;
}.flex-shrink-2 {flex-shrink: 2;
}.flex-shrink-3 {flex-shrink: 3;
}// 设置子项的伸缩基准
.flex-basis-auto {flex-basis: auto;
}.flex-basis-fill {flex-basis: fill;
}.flex-basis-content {flex-basis: content;
}.flex-basis-percent {flex-basis: 50%;
}// margin布局样式
.m-auto {margin: auto;
}.mt-auto {margin-top: auto;
}.mr-auto {margin-right: auto;
}.mb-auto {margin-bottom: auto;
}.ml-auto {margin-left: auto;
}.mx-auto {margin-left: auto;margin-right: auto;
}.my-auto {margin-top: auto;margin-bottom: auto;
}@for $i from -100 through 100 {.margin-#{$i} {margin: #{$i}px;}
}@for $i from -100 through 100 {.mt-#{$i} {margin-top: #{$i}px;}
}@for $i from -100 through 100 {.mr-#{$i} {margin-right: #{$i}px;}
}@for $i from -100 through 100 {.mb-#{$i} {margin-bottom: #{$i}px;}
}@for $i from -100 through 100 {.margin-left-#{$i} {margin-left: #{$i}px;}
}@for $i from -100 through 100 {.my-#{$i} {margin-top: #{$i}px;margin-bottom: #{$i}px;}
}@for $i from -100 through 100 {.mx-#{$i} {margin-right: #{$i}px;margin-left: #{$i}px;}
}// 背景颜色
@each $name, $color in $colors {.bg-#{$name} {background-color: $color;}
}// 宽度
@for $i from 10 through 750 {.w-#{$i} {width: #{$i}rpx;}
}// 宽度-%百分比
@for $i from 1 through 100 {.w-#{$i}P {width: #{$i* 1%};}
}// 屏幕宽度
@for $i from 1 through 100 {.w-#{$i}vw {width: #{$i}vw;}
}// 高度
@for $i from 10 through 800 {.h-#{$i} {height: #{$i}rpx;}
}// 高度-%百分比
@for $i from 1 through 100 {.h-#{$i}P {height: #{$i* 1%};}
}// 屏幕高度
@for $i from 1 through 100 {.h-#{$i}vh {height: #{$i}vh;}
}// 内边距
@for $i from 1 through 50 {.p-#{$i} {padding: #{$i}px;}
}// 上内边距
@for $i from 1 through 50 {.pt-#{$i} {padding-top: #{$i}px;}
}// 右内边距
@for $i from 1 through 50 {.pr-#{$i} {padding-right: #{$i}px;}
}// 下内边距
@for $i from 1 through 50 {.pb-#{$i} {padding-bottom: #{$i}px;}
}// 左内边距
@for $i from 1 through 50 {.pl-#{$i} {padding-left: #{$i}px;}
}// 上下内边距
@for $i from 1 through 50 {.py-#{$i} {padding-top: #{$i}px;padding-bottom: #{$i}px;}
}// 左右内边距
@for $i from 1 through 50 {.px-#{$i} {padding-left: #{$i}px;padding-right: #{$i}px;}
}// 圆角
@for $i from 1 through 50 {.radius-#{$i} {border-radius: #{$i}px;}
}// 间隔
// 宽度
@for $i from 1 through 50 {.gap-#{$i} {gap: #{$i}rpx;}
}// 阴影
$shadows: (sm: (0 1px 2px 0 rgba(0, 0, 0, 0.05)),default: (0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1)),md: (0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1)),lg: (0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1)),xl: (0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1)),'2xl': (0 25px 50px -12px rgba(0, 0, 0, 0.25)),inner: (inset 0 2px 4px 0 rgba(0, 0, 0, 0.05)),none: (0 0 rgba(0, 0, 0, 0))
);@each $name, $value in $shadows {.shadow-#{$name} {box-shadow: $value;}
}// 边框
@for $i from 1 through 50 {@each $color-name, $color-value in $colors {.border-#{$i}-#{$color-name} {border: #{$i}px solid $color-value;}}
}@for $i from 1 through 50 {@each $color-name, $color-value in $colors {.border-top-#{$i}-#{$color-name} {border-top: #{$i}px solid $color-value;}.border-right-#{$i}-#{$color-name} {border-right: #{$i}px solid $color-value;}.border-bottom-#{$i}-#{$color-name} {border-bottom: #{$i}px solid $color-value;}.border-left-#{$i}-#{$color-name} {border-left: #{$i}px solid $color-value;}.border-x-#{$i}-#{$color-name} {border-left: #{$i}px solid $color-value;border-right: #{$i}px solid $color-value;}.border-y-#{$i}-#{$color-name} {border-top: #{$i}px solid $color-value;border-bottom: #{$i}px solid $color-value;}}
}// 父元素的1/2 使用方法:father-1_2
@for $i from 2 through 10 {.father-1_#{$i} {width: percentage(1 / $i); // 子元素宽度为父元素的分数}
}// 圆形,直径从5-100
@for $i from 5 through 100 {.circle-#{$i} {width: #{$i}px;height: #{$i}px;border-radius: 50%;}
}// 位于屏幕的最底部位置
.bottom-element {position: fixed;z-index: 1000; // 可以根据实际情况调整 z-indexbottom: 0;left: 0;right: 0;
}// 按钮的基本样式
.btn {transition: background-color 0.3s ease;
}// 按钮的点击后样式
.btn:active {background-color: #ff6600;
}

这篇关于uniapp使用scss仿tailwindcss进行常用样式封装便捷开发小程序或web的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/938201

相关文章

python获取指定名字的程序的文件路径的两种方法

《python获取指定名字的程序的文件路径的两种方法》本文主要介绍了python获取指定名字的程序的文件路径的两种方法,文中通过示例代码介绍的非常详细,对大家的学习或者工作具有一定的参考学习价值,需要... 最近在做项目,需要用到给定一个程序名字就可以自动获取到这个程序在Windows系统下的绝对路径,以下

Vue和React受控组件的区别小结

《Vue和React受控组件的区别小结》本文主要介绍了Vue和React受控组件的区别小结,文中通过示例代码介绍的非常详细,对大家的学习或者工作具有一定的参考学习价值,需要的朋友们下面随着小编来一起学... 目录背景React 的实现vue3 的实现写法一:直接修改事件参数写法二:通过ref引用 DOMVu

Java使用Javassist动态生成HelloWorld类

《Java使用Javassist动态生成HelloWorld类》Javassist是一个非常强大的字节码操作和定义库,它允许开发者在运行时创建新的类或者修改现有的类,本文将简单介绍如何使用Javass... 目录1. Javassist简介2. 环境准备3. 动态生成HelloWorld类3.1 创建CtC

使用Python批量将.ncm格式的音频文件转换为.mp3格式的实战详解

《使用Python批量将.ncm格式的音频文件转换为.mp3格式的实战详解》本文详细介绍了如何使用Python通过ncmdump工具批量将.ncm音频转换为.mp3的步骤,包括安装、配置ffmpeg环... 目录1. 前言2. 安装 ncmdump3. 实现 .ncm 转 .mp34. 执行过程5. 执行结

Java实现将HTML文件与字符串转换为图片

《Java实现将HTML文件与字符串转换为图片》在Java开发中,我们经常会遇到将HTML内容转换为图片的需求,本文小编就来和大家详细讲讲如何使用FreeSpire.DocforJava库来实现这一功... 目录前言核心实现:html 转图片完整代码场景 1:转换本地 HTML 文件为图片场景 2:转换 H

Java使用jar命令配置服务器端口的完整指南

《Java使用jar命令配置服务器端口的完整指南》本文将详细介绍如何使用java-jar命令启动应用,并重点讲解如何配置服务器端口,同时提供一个实用的Web工具来简化这一过程,希望对大家有所帮助... 目录1. Java Jar文件简介1.1 什么是Jar文件1.2 创建可执行Jar文件2. 使用java

C#使用Spire.Doc for .NET实现HTML转Word的高效方案

《C#使用Spire.Docfor.NET实现HTML转Word的高效方案》在Web开发中,HTML内容的生成与处理是高频需求,然而,当用户需要将HTML页面或动态生成的HTML字符串转换为Wor... 目录引言一、html转Word的典型场景与挑战二、用 Spire.Doc 实现 HTML 转 Word1

Vue3绑定props默认值问题

《Vue3绑定props默认值问题》使用Vue3的defineProps配合TypeScript的interface定义props类型,并通过withDefaults设置默认值,使组件能安全访问传入的... 目录前言步骤步骤1:使用 defineProps 定义 Props步骤2:设置默认值总结前言使用T

Java中的抽象类与abstract 关键字使用详解

《Java中的抽象类与abstract关键字使用详解》:本文主要介绍Java中的抽象类与abstract关键字使用详解,本文通过实例代码给大家介绍的非常详细,感兴趣的朋友跟随小编一起看看吧... 目录一、抽象类的概念二、使用 abstract2.1 修饰类 => 抽象类2.2 修饰方法 => 抽象方法,没有

SpringBoot 多环境开发实战(从配置、管理与控制)

《SpringBoot多环境开发实战(从配置、管理与控制)》本文详解SpringBoot多环境配置,涵盖单文件YAML、多文件模式、MavenProfile分组及激活策略,通过优先级控制灵活切换环境... 目录一、多环境开发基础(单文件 YAML 版)(一)配置原理与优势(二)实操示例二、多环境开发多文件版