Newer
Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
This is just a help to make your component documentation in order to
save time and to be exhautif. Take the freedom you want!
SIB [short name of the functionality]
=====================================
The description of your functionality should be clear and should be
the same as the description of your project
``<sib-[name]>`` is [description].
Try the demo
------------
It’s a good practice to set a demo in each functionality.
To launch the demo, please run at the root of the component :
.. code:: bash
python3 -m http.server 8001
Installation
------------
Explain how to connect your component to the right back end Django
module.
In your django project, add the ``djangoldp_[name]`` package:
.. code:: python
# settings.py
DJANGOLDP_PACKAGES = [
'djangoldp_[name]',
]
How to use
----------
Show how to implement it.
Once the package is installed, you can use the ``sib-[name]`` component:
.. code:: html
<html>
<head>
<!-- import the module in the head of the page -->
<script type="module" src="link/to/your/component"></script>
</head>
<body>
<!-- use the component -->
<sib-name
data-src="[url]"
attribute1='1'
attribute2='xyz'>
</sib-name>
</body>
</html>
Notes : > Anything to add about how it works?
Parameters
~~~~~~~~~~
+-------------------+---------------+--------------------------------+
| Name | Default | Description |
+===================+===============+================================+
| ``data-src`` | ``undefined`` | URL of .. |
+-------------------+---------------+--------------------------------+
| ``extra-context`` | ``{}`` | Custom extra context |
+-------------------+---------------+--------------------------------+
| ``attribute1`` | ``10`` | Explanation about the |
| | | attribute named ‘attribute1’ |
+-------------------+---------------+--------------------------------+
A personal message
------------------
Feel free to share a personal message with your readers. Don’t forget to
share here your mail address as well!
Hoping it was useful!