msaisrinivas / BlinkListApp

Prefer boolean attributes notation in JSX JS-0400
Anti-pattern
Minor
a year agoa year old
Value must be omitted for boolean attributes
36})
37
38test("Header Account Icon click Test",async () => {
39    render(<BrowserRouter> <Header avatarIcon={true}/> </BrowserRouter>);40    const headerElement = screen.getByTestId(/PersonIcon/i);
41    expect(headerElement).toBe(headerElement);
42})
Value must be omitted for boolean attributes
55          <CardsList finished={true} checkComplete={31}></CardsList>
56        </TabPanel>
57        <TabPanel value="2" data-testid={"tab-panel2"}>
58        <CardsList readAgain={true} checkComplete={100}></CardsList>59        </TabPanel>
60      </TabContext>
61    </StyledEngineProvider>
Value must be omitted for boolean attributes
52          </TabList>
53        </Box>
54        <TabPanel value="1" data-testid={"tab-panel1"}>
55          <CardsList finished={true} checkComplete={31}></CardsList>56        </TabPanel>
57        <TabPanel value="2" data-testid={"tab-panel2"}>
58        <CardsList readAgain={true} checkComplete={100}></CardsList>
Value must be omitted for boolean attributes
74                image={card.src}
75                bookName={card.title}
76                authorName={card.author}
77                progress={true}78                librarybu={props.librarybu}
79                finished={props.finished}
80                readAgain={props.readAgain}
Value must be omitted for boolean attributes
2import CardsList from "."
3
4it("CardsList Test" ,async () => {
5    render(<CardsList checkComplete={0} librarybu={true} />);6    const cardsListElement = screen.getByText(/No Books to Show/i);
7    expect(cardsListElement).toBeInTheDocument();
8})