Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

281
Views
Istanbul ignore next not working inside JSX and nested arrays

I'm trying to use instanbul ignore next to ignore some lines in my test coverage but it dont work inside a JSX or nested array. Anyone have an idea of what I can do?

          <Text
            as="span" /* istanbul ignore next */ - IT WONT WORK HERE
            variant={isMobile ? 'medParagraph' : 'smParagraph'} //im trying to ignore this line
            sx={{
              fontWeight: selected ? 'bold' : undefined,
            }}>
            {page}
          </Text>

  const itemList = [
    ...(siblingsEnd < count - boundaryCount - 1
      ? ['end-ellipsis']
      : count - boundaryCount > boundaryCount
      ? [count - boundaryCount]
      : []),
    /* istanbul ignore next */ - WONT WORK HERE AS WELL
    ...endPages, //im trying to ignore this line
    ...(hideNextButton ? [] : ['next']),
    ...(showLastButton ? ['last'] : []),
  ];
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

I was able to ignore the nested array placing the istanbul above the const definition.

Same with the JSX, I just placed the istanbul above the return.

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!