Skip to content

Latest commit

 

History

History
60 lines (42 loc) · 1.07 KB

no-escape-hatch.md

File metadata and controls

60 lines (42 loc) · 1.07 KB

no-escape-hatch

Prohibit the use of escape hatch syntax in the code.

📋 This rule is enabled in plugin:@pandacss/all.

Rule details

❌ Examples of incorrect code:

import { css } from './panda/css';

const styles = css({ marginLeft: '[4px]' });
import { css } from './panda/css';

function App(){
  return <div className={css({ background: '[#111]' })} />;
};
import { Circle } from './panda/jsx';

function App(){
  return <Circle _hover={{ position: '[absolute]' }} />;
}

✔️ Examples of correct code:

import { css } from './panda/css';

const styles = css({ marginLeft: '4' });
import { css } from './panda/css';

function App(){
  return <div className={css({ background: 'red.100' })} />;
};
import { Circle } from './panda/jsx';

function App(){
  return <Circle _hover={{ position: 'absolute' }} />;
}

Resources