We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 89007f6 commit 7964deeCopy full SHA for 7964dee
1 file changed
README.md
@@ -17,6 +17,21 @@
17
<script src="../webcomponentsjs/webcomponents-lite.js"></script>
18
<script src="../smart-core/source/smart.core.js"></script>
19
<link rel="stylesheet" href="../smart-core/source/styles/smart.default.css" type="text/css" />
20
+ <script>
21
+ window.onload = function () {
22
+ const basePath = '/images/',
23
+ carouselSquare = document.getElementById('carouselSquare'),
24
+
25
+ carouselSquare.dataSource = generateDataSource(7);
26
27
+ function generateDataSource(items) {
28
+ let dataSource = Array(items).fill({});
29
30
+ dataSource.forEach((element, index) => dataSource[index] = { image: `${basePath}carousel-square-${index + 1}.jpg` });
31
+ return dataSource;
32
+ }
33
+}
34
+ </script>
35
<next-code-block></next-code-block>
36
</template>
37
</custom-element-demo>
0 commit comments