Fetch API cannot load file

Is there a way to ask the user to use data from an other directory in JS ?