5

I updated from Vapor 3 to 4, and Xcode 11 to 12. Now Leaf cannot find my *.leaf templates. I get a "noTemplateFile" error.

AlexMath
  • 567
  • 1
  • 6
  • 16

2 Answers2

14

I found the answer here: https://theswiftdev.com/how-to-create-your-first-website-using-vapor-4-and-leaf/

The trick was to add a "Custom Working Directory" in the scheme's options. I added my project's root directory and it worked.

AlexMath
  • 567
  • 1
  • 6
  • 16
2

Just modify your schema to be the directory for your Vapor server. Step by step guideline here https://docs.vapor.codes/4.0/xcode/

zdravko zdravkin
  • 2,090
  • 19
  • 21