From 3a97249bc9379bc2e3927595afa1980f2e34b388 Mon Sep 17 00:00:00 2001 From: ArlingtonHouse Date: Sun, 10 Sep 2017 08:33:28 -0400 Subject: [PATCH 1/2] add empty h1 tags to html template First Example tutorial needs the tag in order to work. --- frontend/encore/simple-example.rst | 1 + 1 file changed, 1 insertion(+) diff --git a/frontend/encore/simple-example.rst b/frontend/encore/simple-example.rst index 8722b0bdd74..c72a539c4a0 100644 --- a/frontend/encore/simple-example.rst +++ b/frontend/encore/simple-example.rst @@ -96,6 +96,7 @@ In Symfony, use the ``asset()`` helper: +

From e7642f73dedb0ca89dbd15a319db5d75cdf1d76c Mon Sep 17 00:00:00 2001 From: Ryan Weaver Date: Tue, 21 Nov 2017 08:14:08 -0500 Subject: [PATCH 2/2] removing h1 but making JS more fool-proof --- frontend/encore/simple-example.rst | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/frontend/encore/simple-example.rst b/frontend/encore/simple-example.rst index c72a539c4a0..e7f21149fa8 100644 --- a/frontend/encore/simple-example.rst +++ b/frontend/encore/simple-example.rst @@ -96,7 +96,6 @@ In Symfony, use the ``asset()`` helper: -

@@ -135,7 +134,7 @@ Great! Use ``require()`` to import ``jquery`` and ``greet.js``: var greet = require('./greet'); $(document).ready(function() { - $('h1').html(greet('john')); + $('body').prepend('

'+greet('john')+'

'); }); That's it! When you build your assets, jQuery and ``greet.js`` will automatically