leomrocha/docx4u

Template files are copied, they shouldn't

leomrocha opened this issue · 0 comments

FileList.tsx copies the files when they are selected for to a new directory.

Files should not be copied, only the original used and never modified by the program.
Copying files has at least the following usage problems:

  • Having a copy will confuse users as if (when) they modify their template the copy will not be modified, and the program will keep looking at the copied (outdated) file
  • More file management code to do and maintain
  • Also if a copy exists it might be erased by the user (the user didn't create them, might think it's OK to erase it)
  • This copy does not seem to be working in linux (the folder is not created or created somewhere else)

Even if for a first MVP there is no need to check the state, but it is a good feature for a next stage
A simpler approach is only create a file that contains the database with the details of where the templates exist and the last state of the application (like it's done now)