Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
export function readingTime(markdown: string): rTimeResponse {
const text = markdown.split('\n').filter(
line => !lineRepresentsEncodedComponent(line)).join('\n');
// make sure there's at least one latin char in your string otherwise we get
// a funny error from our estimator which complains with a `Data provided is invalid`
return rTime(`a${text}`);
}