Skip to content

Commit 27a592b

Browse files
committed
Implement normalized controller names
1 parent c687d68 commit 27a592b

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ page has been rendered:
3131
```twig
3232
<img
3333
src="{{ asset('image/small.png') }}"
34-
data-controller="@symfony/ux-lazy-image/lazy-image"
34+
data-controller="symfony--ux-lazy-image--lazy-image"
3535
data-hd-src="{{ asset('image/large.png') }}"
3636
3737
{# Optional but avoids having a page jump when the image is loaded #}
@@ -46,7 +46,7 @@ the BlurHash algorithm to create a light, blurred, data-uri thumbnail of the ima
4646
```twig
4747
<img
4848
src="{{ data_uri_thumbnail('public/image/large.png', 100, 75) }}"
49-
data-controller="@symfony/ux-lazy-image/lazy-image"
49+
data-controller="symfony--ux-lazy-image--lazy-image"
5050
data-hd-src="{{ asset('image/large.png') }}"
5151
5252
{# Using BlurHash, the size is required #}
@@ -101,7 +101,7 @@ Then in your template, add your controller to the HTML attribute:
101101
```twig
102102
<img
103103
src="{{ data_uri_thumbnail('public/image/large.png', 100, 75) }}"
104-
data-controller="mylazyimage @symfony/ux-lazy-image/lazy-image"
104+
data-controller="mylazyimage symfony--ux-lazy-image--lazy-image"
105105
data-hd-src="{{ asset('image/large.png') }}"
106106
107107
{# Using BlurHash, the size is required #}

Resources/assets/dist/controller.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,15 @@
88
*/
99
'use strict';
1010

11+
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
12+
1113
Object.defineProperty(exports, "__esModule", {
1214
value: true
1315
});
1416
exports["default"] = void 0;
1517

1618
var _stimulus = require("stimulus");
1719

18-
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
19-
2020
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
2121

2222
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }

0 commit comments

Comments
 (0)