Корректно нормализируем пути в JS
import * as path from 'path';
const normalize = (rootPath, childPath) => {
   const normalizedPath = path.normalize(`${rootPath}/${childPath}`); 
   
   if (normalizedPath.startsWith(`${rootPath}/`)) {
      return normalizedPath;
   }
   return null;  
}PreviousБорьба с CORS и Local File Read в браузереNextТестирование работы с медленными ответами (slow js http response)
Last updated