aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/com/juick/config/WebConfig.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/com/juick/config/WebConfig.java')
-rw-r--r--src/main/java/com/juick/config/WebConfig.java13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/main/java/com/juick/config/WebConfig.java b/src/main/java/com/juick/config/WebConfig.java
index 59f9a99c..bfebd77f 100644
--- a/src/main/java/com/juick/config/WebConfig.java
+++ b/src/main/java/com/juick/config/WebConfig.java
@@ -23,14 +23,16 @@ import com.juick.service.HelpService;
import com.juick.service.StorageService;
import com.juick.service.FileSystemStorageService;
import com.juick.service.UserService;
-import com.mitchellbosecke.pebble.PebbleEngine;
import com.mitchellbosecke.pebble.extension.FormatterExtension;
-import com.mitchellbosecke.pebble.loader.ClasspathLoader;
-import com.mitchellbosecke.pebble.loader.Loader;
-import com.mitchellbosecke.pebble.spring.extension.SpringExtension;
-import com.mitchellbosecke.pebble.spring.servlet.PebbleViewResolver;
import com.overzealous.remark.Options;
import com.overzealous.remark.Remark;
+
+import io.pebbletemplates.pebble.PebbleEngine;
+import io.pebbletemplates.pebble.loader.ClasspathLoader;
+import io.pebbletemplates.pebble.loader.Loader;
+import io.pebbletemplates.spring.extension.SpringExtension;
+import io.pebbletemplates.spring.servlet.PebbleViewResolver;
+
import org.apache.commons.codec.CharEncoding;
import org.commonmark.ext.autolink.AutolinkExtension;
import org.commonmark.node.Link;
@@ -175,6 +177,7 @@ public class WebConfig implements WebMvcConfigurer {
viewResolver.setPrefix("templates");
viewResolver.setSuffix(".html");
viewResolver.setCharacterEncoding(CharEncoding.UTF_8);
+ viewResolver.setExposeRequestAttributes(true);
return viewResolver;
}
@Override