@justeattakeaway/pie-cookie-banner 1.3.0 → 1.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +24 -0
  2. package/package.json +6 -3
package/README.md CHANGED
@@ -30,6 +30,30 @@ yarn add @justeattakeaway/pie-cookie-banner
30
30
 
31
31
  For full information on using PIE components as part of an application, check out the [Getting Started Guide](https://github.com/justeattakeaway/pie/wiki/Getting-started-with-PIE-Web-Components).
32
32
 
33
+ ## CDN Usage
34
+
35
+ This is not the recommended way to use the component. However, it may be appropriate for some consumers if they are unable to install the package into their application.
36
+
37
+ Example (without typography) can be seen in this [Codepen](https://codepen.io/JamieMaguire/pen/emYGwgy)
38
+
39
+ To check for the most up-to-date versions of our cookie banner and css, check their npm pages [here](https://www.npmjs.com/package/@justeattakeaway/pie-cookie-banner) and [here](https://www.npmjs.com/package/@justeattakeaway/pie-css). It is important to stay up to date. These will be the versions you use in the CDN links.
40
+
41
+ ### Setup
42
+
43
+ 1. Please add the `pie-css` stylesheet to your application. This can be imported from our CDN like so:
44
+
45
+ ```html
46
+ <link rel="stylesheet" href="https://pie-design-system-cdn.production.jet-external.com/pie-css/v0.16.0/index.css">
47
+ ```
48
+
49
+ 2. Now you can add the Cookie Banner script to your application. This can also be imported from our CDN like so:
50
+
51
+ ```html
52
+ <script src="https://pie-design-system-cdn.production.jet-external.com/pie-cookie-banner/v1.4.0/index.js"></script>
53
+ ```
54
+
55
+ We would recommend placing this script somewhere in the bottom of your HTML body tag. However what works for each application will be different. Please consider how this could affect the loading of your page.
56
+
33
57
  ## Documentation
34
58
 
35
59
  Visit [Cookie Banner | PIE Design System](https://pie.design/patterns/cookie-banner/code/) to view more information on this component.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@justeattakeaway/pie-cookie-banner",
3
3
  "description": "PIE Design System Cookie Banner built using Web Components",
4
- "version": "1.3.0",
4
+ "version": "1.4.1",
5
5
  "repository": {
6
6
  "type": "git",
7
7
  "url": "https://github.com/justeattakeaway/pie",
@@ -21,7 +21,10 @@
21
21
  "**/*.d.ts"
22
22
  ],
23
23
  "pieMetadata": {
24
- "componentStatus": "stable"
24
+ "componentStatus": "stable",
25
+ "cdnPublish": true,
26
+ "cdnSourceFolder": "cdn_dist",
27
+ "cdnContentType": "text/javascript"
25
28
  },
26
29
  "scripts": {
27
30
  "build": "run -T vite build && yarn build:cdn",
@@ -45,7 +48,7 @@
45
48
  "devDependencies": {
46
49
  "@custom-elements-manifest/analyzer": "0.9.0",
47
50
  "@justeattakeaway/pie-components-config": "0.18.0",
48
- "@justeattakeaway/pie-css": "0.15.1",
51
+ "@justeattakeaway/pie-css": "0.16.0",
49
52
  "@justeattakeaway/pie-wrapper-react": "0.14.3",
50
53
  "cem-plugin-module-file-extensions": "0.0.5"
51
54
  },