mirror of
https://github.com/overleaf/overleaf.git
synced 2024-12-11 12:56:42 -05:00
13 lines
273 B
JavaScript
13 lines
273 B
JavaScript
|
import ExposedSettings from './exposed-settings'
|
||
|
|
||
|
const validTeXFileRegExp = new RegExp(
|
||
|
`\\.(${ExposedSettings.validRootDocExtensions.join('|')})$`,
|
||
|
'i'
|
||
|
)
|
||
|
|
||
|
function isValidTeXFile(filename) {
|
||
|
return validTeXFileRegExp.test(filename)
|
||
|
}
|
||
|
|
||
|
export default isValidTeXFile
|