Is there a way to detect unnecessary CSS inline styles that are typed but not actually needed?
For example, in a .js file:
line: {
borderBottom: '1px #ddd solid',
paddingBottom: '5px',
backgroundColor: 'white',
border: '1px solid #ddd',
padding: '10px',
marginTop: '10px',
marginBottom: '10px',
borderRadius: '5px',
textAlign: 'center',
},
container: {
},
In the file where the .js is called:
<div style={styles.line}>
For example, in the file using the style, the container is not necessary, or all styles defined in `styles.line` may not be needed (resulting in excess styling). Is there a tool or lint that can automatically detect and flag these unnecessary styles for warning or deletion?
Thank you.