Figure out why the background color is wrong for codeblocks that don't have a language
kentcdodds opened this issue Β· comments
That should all just be a single solid color instead of the wrapping dark/blue color around it.
its @kentcdodds/md-temp
const className = codeNode.properties?.className;
- if (!isArrayOfStrings(className))
+ if (typeof className !== 'undefined' && !isArrayOfStrings(className))
return;
const language = className
- .find(c => c.startsWith('language-'))
+ ?.find(c => c.startsWith('language-'))
?.slice('language-'.length) ?? 'txt';
when there is no language codeNode.properties?.className is undefined
,
I think that's fine. What I'm thinking is we just need to fix some of the CSS so the color is correct π€
π This issue has been resolved in version 2.8.1 π
The release is available on:
Your semantic-release bot π¦π