🌈 style(eslint): add eslint rules
This commit is contained in:
@@ -8,9 +8,10 @@
|
||||
*/
|
||||
|
||||
import { View } from '@tarojs/components'
|
||||
import React, { FC, ReactNode } from 'react'
|
||||
import styles from './index.module.scss'
|
||||
import type { FC, ReactNode } from 'react'
|
||||
import React from 'react'
|
||||
import classnames from 'classnames'
|
||||
import styles from './index.module.scss'
|
||||
|
||||
type BorderStype = 'solid' | 'dashed' | 'dotted' | 'double'
|
||||
|
||||
@@ -25,8 +26,8 @@ interface DividerProps {
|
||||
const Divider: FC<DividerProps> = (props) => {
|
||||
const { direction = 'horizontal', borderStyle = 'solid', contentPosition = 'center', customClassName = '', customStyles = {} } = props
|
||||
|
||||
const classname = classnames(styles['divider'], styles['divider-' + direction], customClassName)
|
||||
const contentClassname = classnames(styles['divider-text'], styles['is-' + contentPosition])
|
||||
const classname = classnames(styles.divider, styles[`divider-${direction}`], customClassName)
|
||||
const contentClassname = classnames(styles['divider-text'], styles[`is-${contentPosition}`])
|
||||
|
||||
const borderTopStyle: { borderTopStyle: BorderStype } = {
|
||||
borderTopStyle: borderStyle,
|
||||
|
||||
Reference in New Issue
Block a user