Open yogiswar1987 opened 1 year ago
if i create views/partials. folder, below is the error
error: Uncaught NotFound: No such file or directory (os error 2) const source: string = new TextDecoder().decode(await readFile(path)); ^ at async readFile (deno:runtime/js/40_read_file.js:25:20) at async Handlebars.render (https://deno.land/x/handlebars@v0.9.0/mod.ts:109:53) at async Handlebars.renderView (https://deno.land/x/handlebars@v0.9.0/mod.ts:84:26) at async file:///Users/yreddivari/WebstormProjects/deno-handlebars/index.ts:5:13
After creating layouts/main.hbs below is the response
<div>layout-main</div>
which is content of layouts/main.hbs
Coded just how you asked in a bug Using MAC Monterey 12.6 Deno 1.28.3
getting below error
IN-MAC-163:ott yreddivari$ deno run --allow-read index.ts Download ⠇ https://deno.land/x/oak/mod.ts Warning Implicitly using latest version (v11.1.0) for https://deno.land/x/oak/mod.ts Download ⠋ https://deno.land/x/oak@v11.1.0/mod.ts Warning Implicitly using latest version (v0.9.0) for https://deno.land/x/handlebars/mod.ts error: Uncaught Error: No such file or directory (os error 2), readdir 'views/partials/' for path "views/partials/"