@metamask/snaps-cli 0.38.1-flask.1 → 1.0.0

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 (253) hide show
  1. package/CHANGELOG.md +377 -19
  2. package/README.md +67 -542
  3. package/dist/builders.d.ts +27 -0
  4. package/dist/{esm/builders.js → builders.js} +51 -48
  5. package/dist/builders.js.map +1 -0
  6. package/dist/{types/cli.d.ts → cli.d.ts} +1 -1
  7. package/dist/cli.js +51 -0
  8. package/dist/cli.js.map +1 -0
  9. package/dist/cmds/build/buildHandler.d.ts +13 -0
  10. package/dist/cmds/build/buildHandler.js +37 -0
  11. package/dist/cmds/build/buildHandler.js.map +1 -0
  12. package/dist/cmds/build/bundle.d.ts +15 -0
  13. package/dist/cmds/build/bundle.js +80 -0
  14. package/dist/cmds/build/bundle.js.map +1 -0
  15. package/dist/{types/commands/serve → cmds/build}/index.d.ts +4 -4
  16. package/dist/cmds/build/index.js +29 -0
  17. package/dist/cmds/build/index.js.map +1 -0
  18. package/dist/cmds/build/utils.d.ts +56 -0
  19. package/dist/cmds/build/utils.js +100 -0
  20. package/dist/cmds/build/utils.js.map +1 -0
  21. package/dist/cmds/eval/evalHandler.d.ts +9 -0
  22. package/dist/cmds/eval/evalHandler.js +25 -0
  23. package/dist/cmds/eval/evalHandler.js.map +1 -0
  24. package/dist/cmds/eval/index.d.ts +9 -0
  25. package/dist/cmds/eval/index.js +15 -0
  26. package/dist/cmds/eval/index.js.map +1 -0
  27. package/dist/cmds/index.js +14 -0
  28. package/dist/cmds/index.js.map +1 -0
  29. package/dist/cmds/init/index.d.ts +9 -0
  30. package/dist/cmds/init/index.js +34 -0
  31. package/dist/cmds/init/index.js.map +1 -0
  32. package/dist/cmds/init/initHandler.d.ts +26 -0
  33. package/dist/cmds/init/initHandler.js +69 -0
  34. package/dist/cmds/init/initHandler.js.map +1 -0
  35. package/dist/cmds/init/initUtils.d.ts +39 -0
  36. package/dist/cmds/init/initUtils.js +122 -0
  37. package/dist/cmds/init/initUtils.js.map +1 -0
  38. package/dist/cmds/manifest/index.d.ts +9 -0
  39. package/dist/cmds/manifest/index.js +24 -0
  40. package/dist/cmds/manifest/index.js.map +1 -0
  41. package/dist/cmds/manifest/manifestHandler.d.ts +10 -0
  42. package/dist/cmds/manifest/manifestHandler.js +50 -0
  43. package/dist/cmds/manifest/manifestHandler.js.map +1 -0
  44. package/dist/cmds/serve/index.d.ts +9 -0
  45. package/dist/cmds/serve/index.js +15 -0
  46. package/dist/cmds/serve/index.js.map +1 -0
  47. package/dist/cmds/serve/serveHandler.d.ts +10 -0
  48. package/dist/cmds/serve/serveHandler.js +59 -0
  49. package/dist/cmds/serve/serveHandler.js.map +1 -0
  50. package/dist/cmds/serve/serveUtils.d.ts +22 -0
  51. package/dist/cmds/serve/serveUtils.js +39 -0
  52. package/dist/cmds/serve/serveUtils.js.map +1 -0
  53. package/dist/cmds/watch/index.d.ts +9 -0
  54. package/dist/cmds/watch/index.js +32 -0
  55. package/dist/cmds/watch/index.js.map +1 -0
  56. package/dist/cmds/watch/watchHandler.d.ts +14 -0
  57. package/dist/cmds/watch/watchHandler.js +100 -0
  58. package/dist/cmds/watch/watchHandler.js.map +1 -0
  59. package/dist/main.js +15 -0
  60. package/dist/main.js.map +1 -0
  61. package/dist/utils/index.d.ts +2 -0
  62. package/dist/utils/index.js +19 -0
  63. package/dist/utils/index.js.map +1 -0
  64. package/dist/utils/misc.d.ts +53 -0
  65. package/dist/utils/misc.js +156 -0
  66. package/dist/utils/misc.js.map +1 -0
  67. package/dist/utils/snap-config.d.ts +48 -0
  68. package/dist/utils/snap-config.js +117 -0
  69. package/dist/utils/snap-config.js.map +1 -0
  70. package/package.json +35 -54
  71. package/.browserslistrc +0 -3
  72. package/dist/cjs/builders.js +0 -148
  73. package/dist/cjs/builders.js.map +0 -1
  74. package/dist/cjs/cli.js +0 -35
  75. package/dist/cjs/cli.js.map +0 -1
  76. package/dist/cjs/commands/build/build.js +0 -54
  77. package/dist/cjs/commands/build/build.js.map +0 -1
  78. package/dist/cjs/commands/build/implementation.js +0 -31
  79. package/dist/cjs/commands/build/implementation.js.map +0 -1
  80. package/dist/cjs/commands/build/index.js +0 -45
  81. package/dist/cjs/commands/build/index.js.map +0 -1
  82. package/dist/cjs/commands/eval/eval.js +0 -57
  83. package/dist/cjs/commands/eval/eval.js.map +0 -1
  84. package/dist/cjs/commands/eval/implementation.js +0 -27
  85. package/dist/cjs/commands/eval/implementation.js.map +0 -1
  86. package/dist/cjs/commands/eval/index.js +0 -50
  87. package/dist/cjs/commands/eval/index.js.map +0 -1
  88. package/dist/cjs/commands/index.js +0 -30
  89. package/dist/cjs/commands/index.js.map +0 -1
  90. package/dist/cjs/commands/manifest/implementation.js +0 -34
  91. package/dist/cjs/commands/manifest/implementation.js.map +0 -1
  92. package/dist/cjs/commands/manifest/index.js +0 -50
  93. package/dist/cjs/commands/manifest/index.js.map +0 -1
  94. package/dist/cjs/commands/manifest/manifest.js +0 -55
  95. package/dist/cjs/commands/manifest/manifest.js.map +0 -1
  96. package/dist/cjs/commands/serve/index.js +0 -33
  97. package/dist/cjs/commands/serve/index.js.map +0 -1
  98. package/dist/cjs/commands/serve/serve.js +0 -21
  99. package/dist/cjs/commands/serve/serve.js.map +0 -1
  100. package/dist/cjs/commands/watch/implementation.js +0 -35
  101. package/dist/cjs/commands/watch/implementation.js.map +0 -1
  102. package/dist/cjs/commands/watch/index.js +0 -47
  103. package/dist/cjs/commands/watch/index.js.map +0 -1
  104. package/dist/cjs/commands/watch/watch.js +0 -51
  105. package/dist/cjs/commands/watch/watch.js.map +0 -1
  106. package/dist/cjs/config.js +0 -290
  107. package/dist/cjs/config.js.map +0 -1
  108. package/dist/cjs/errors.js +0 -37
  109. package/dist/cjs/errors.js.map +0 -1
  110. package/dist/cjs/index.js +0 -77
  111. package/dist/cjs/index.js.map +0 -1
  112. package/dist/cjs/main.js +0 -19
  113. package/dist/cjs/main.js.map +0 -1
  114. package/dist/cjs/utils/cli.js +0 -61
  115. package/dist/cjs/utils/cli.js.map +0 -1
  116. package/dist/cjs/utils/errors.js +0 -42
  117. package/dist/cjs/utils/errors.js.map +0 -1
  118. package/dist/cjs/utils/index.js +0 -25
  119. package/dist/cjs/utils/index.js.map +0 -1
  120. package/dist/cjs/utils/legacy.js +0 -48
  121. package/dist/cjs/utils/legacy.js.map +0 -1
  122. package/dist/cjs/utils/logging.js +0 -46
  123. package/dist/cjs/utils/logging.js.map +0 -1
  124. package/dist/cjs/utils/path.js +0 -16
  125. package/dist/cjs/utils/path.js.map +0 -1
  126. package/dist/cjs/utils/steps.js +0 -52
  127. package/dist/cjs/utils/steps.js.map +0 -1
  128. package/dist/cjs/webpack/compiler.js +0 -96
  129. package/dist/cjs/webpack/compiler.js.map +0 -1
  130. package/dist/cjs/webpack/config.js +0 -234
  131. package/dist/cjs/webpack/config.js.map +0 -1
  132. package/dist/cjs/webpack/index.js +0 -22
  133. package/dist/cjs/webpack/index.js.map +0 -1
  134. package/dist/cjs/webpack/loaders/browserify.js +0 -97
  135. package/dist/cjs/webpack/loaders/browserify.js.map +0 -1
  136. package/dist/cjs/webpack/loaders/wasm.js +0 -36
  137. package/dist/cjs/webpack/loaders/wasm.js.map +0 -1
  138. package/dist/cjs/webpack/plugins.js +0 -340
  139. package/dist/cjs/webpack/plugins.js.map +0 -1
  140. package/dist/cjs/webpack/utils.js +0 -133
  141. package/dist/cjs/webpack/utils.js.map +0 -1
  142. package/dist/esm/builders.js.map +0 -1
  143. package/dist/esm/cli.js +0 -26
  144. package/dist/esm/cli.js.map +0 -1
  145. package/dist/esm/commands/build/build.js +0 -51
  146. package/dist/esm/commands/build/build.js.map +0 -1
  147. package/dist/esm/commands/build/implementation.js +0 -27
  148. package/dist/esm/commands/build/implementation.js.map +0 -1
  149. package/dist/esm/commands/build/index.js +0 -17
  150. package/dist/esm/commands/build/index.js.map +0 -1
  151. package/dist/esm/commands/eval/eval.js +0 -54
  152. package/dist/esm/commands/eval/eval.js.map +0 -1
  153. package/dist/esm/commands/eval/implementation.js +0 -24
  154. package/dist/esm/commands/eval/implementation.js.map +0 -1
  155. package/dist/esm/commands/eval/index.js +0 -22
  156. package/dist/esm/commands/eval/index.js.map +0 -1
  157. package/dist/esm/commands/index.js +0 -15
  158. package/dist/esm/commands/index.js.map +0 -1
  159. package/dist/esm/commands/manifest/implementation.js +0 -33
  160. package/dist/esm/commands/manifest/implementation.js.map +0 -1
  161. package/dist/esm/commands/manifest/index.js +0 -22
  162. package/dist/esm/commands/manifest/index.js.map +0 -1
  163. package/dist/esm/commands/manifest/manifest.js +0 -52
  164. package/dist/esm/commands/manifest/manifest.js.map +0 -1
  165. package/dist/esm/commands/serve/index.js +0 -18
  166. package/dist/esm/commands/serve/index.js.map +0 -1
  167. package/dist/esm/commands/serve/serve.js +0 -17
  168. package/dist/esm/commands/serve/serve.js.map +0 -1
  169. package/dist/esm/commands/watch/implementation.js +0 -34
  170. package/dist/esm/commands/watch/implementation.js.map +0 -1
  171. package/dist/esm/commands/watch/index.js +0 -19
  172. package/dist/esm/commands/watch/index.js.map +0 -1
  173. package/dist/esm/commands/watch/watch.js +0 -50
  174. package/dist/esm/commands/watch/watch.js.map +0 -1
  175. package/dist/esm/config.js +0 -294
  176. package/dist/esm/config.js.map +0 -1
  177. package/dist/esm/errors.js +0 -30
  178. package/dist/esm/errors.js.map +0 -1
  179. package/dist/esm/index.js +0 -6
  180. package/dist/esm/index.js.map +0 -1
  181. package/dist/esm/main.js +0 -10
  182. package/dist/esm/main.js.map +0 -1
  183. package/dist/esm/utils/cli.js +0 -43
  184. package/dist/esm/utils/cli.js.map +0 -1
  185. package/dist/esm/utils/errors.js +0 -43
  186. package/dist/esm/utils/errors.js.map +0 -1
  187. package/dist/esm/utils/index.js +0 -8
  188. package/dist/esm/utils/index.js.map +0 -1
  189. package/dist/esm/utils/legacy.js +0 -47
  190. package/dist/esm/utils/legacy.js.map +0 -1
  191. package/dist/esm/utils/logging.js +0 -40
  192. package/dist/esm/utils/logging.js.map +0 -1
  193. package/dist/esm/utils/path.js +0 -13
  194. package/dist/esm/utils/path.js.map +0 -1
  195. package/dist/esm/utils/steps.js +0 -43
  196. package/dist/esm/utils/steps.js.map +0 -1
  197. package/dist/esm/webpack/compiler.js +0 -89
  198. package/dist/esm/webpack/compiler.js.map +0 -1
  199. package/dist/esm/webpack/config.js +0 -236
  200. package/dist/esm/webpack/config.js.map +0 -1
  201. package/dist/esm/webpack/index.js +0 -5
  202. package/dist/esm/webpack/index.js.map +0 -1
  203. package/dist/esm/webpack/loaders/browserify.js +0 -82
  204. package/dist/esm/webpack/loaders/browserify.js.map +0 -1
  205. package/dist/esm/webpack/loaders/wasm.js +0 -26
  206. package/dist/esm/webpack/loaders/wasm.js.map +0 -1
  207. package/dist/esm/webpack/plugins.js +0 -343
  208. package/dist/esm/webpack/plugins.js.map +0 -1
  209. package/dist/esm/webpack/utils.js +0 -160
  210. package/dist/esm/webpack/utils.js.map +0 -1
  211. package/dist/types/__fixtures__/configs/cjs.d.ts +0 -1
  212. package/dist/types/__fixtures__/configs/esm.d.ts +0 -3
  213. package/dist/types/__fixtures__/configs/invalid.d.ts +0 -3
  214. package/dist/types/__fixtures__/configs/javascript/snap.config.d.ts +0 -0
  215. package/dist/types/__fixtures__/configs/typescript/snap.config.d.ts +0 -3
  216. package/dist/types/builders.d.ts +0 -8
  217. package/dist/types/commands/build/build.d.ts +0 -10
  218. package/dist/types/commands/build/implementation.d.ts +0 -10
  219. package/dist/types/commands/build/index.d.ts +0 -10
  220. package/dist/types/commands/eval/__test__/browserify/bad/snap.config.d.ts +0 -3
  221. package/dist/types/commands/eval/__test__/browserify/good/snap.config.d.ts +0 -3
  222. package/dist/types/commands/eval/__test__/webpack/bad/snap.config.d.ts +0 -3
  223. package/dist/types/commands/eval/__test__/webpack/good/snap.config.d.ts +0 -3
  224. package/dist/types/commands/eval/__test__/webpack/snap.config.d.ts +0 -3
  225. package/dist/types/commands/eval/eval.d.ts +0 -14
  226. package/dist/types/commands/eval/implementation.d.ts +0 -9
  227. package/dist/types/commands/eval/index.d.ts +0 -10
  228. package/dist/types/commands/manifest/implementation.d.ts +0 -12
  229. package/dist/types/commands/manifest/index.d.ts +0 -10
  230. package/dist/types/commands/manifest/manifest.d.ts +0 -14
  231. package/dist/types/commands/serve/serve.d.ts +0 -16
  232. package/dist/types/commands/watch/implementation.d.ts +0 -14
  233. package/dist/types/commands/watch/index.d.ts +0 -10
  234. package/dist/types/commands/watch/watch.d.ts +0 -19
  235. package/dist/types/config.d.ts +0 -626
  236. package/dist/types/errors.d.ts +0 -25
  237. package/dist/types/index.d.ts +0 -5
  238. package/dist/types/utils/cli.d.ts +0 -17
  239. package/dist/types/utils/errors.d.ts +0 -23
  240. package/dist/types/utils/index.d.ts +0 -6
  241. package/dist/types/utils/legacy.d.ts +0 -27
  242. package/dist/types/utils/logging.d.ts +0 -22
  243. package/dist/types/utils/path.d.ts +0 -9
  244. package/dist/types/utils/steps.d.ts +0 -17
  245. package/dist/types/webpack/compiler.d.ts +0 -29
  246. package/dist/types/webpack/config.d.ts +0 -37
  247. package/dist/types/webpack/index.d.ts +0 -3
  248. package/dist/types/webpack/loaders/browserify.d.ts +0 -16
  249. package/dist/types/webpack/loaders/wasm.d.ts +0 -20
  250. package/dist/types/webpack/plugins.d.ts +0 -147
  251. package/dist/types/webpack/utils.d.ts +0 -156
  252. /package/dist/{types/commands → cmds}/index.d.ts +0 -0
  253. /package/dist/{types/main.d.ts → main.d.ts} +0 -0
package/CHANGELOG.md CHANGED
@@ -6,28 +6,386 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
- ## [0.38.1-flask.1]
9
+ ## [1.0.0]
10
10
  ### Changed
11
- - Update all examples to use Webpack ([#1632](https://github.com/MetaMask/snaps/pull/1632))
11
+ - No changes this release.
12
12
 
13
- ## [0.38.0-flask.1]
13
+ ## [1.0.0-prerelease.1]
14
+ ### Changed
15
+ - No changes this release.
16
+
17
+ ## [0.32.2]
18
+ ### Changed
19
+ - No changes this release.
20
+
21
+ ## [0.32.1]
22
+ ### Changed
23
+ - No changes this release.
24
+
25
+ ## [0.32.0]
26
+ ### Changed
27
+ - No changes this release.
28
+
29
+ ## [0.31.0]
30
+ ### Changed
31
+ - **BREAKING:** Target `ES2020` ([#1247](https://github.com/MetaMask/snaps-monorepo/pull/1247))
32
+
33
+ ## [0.30.0]
34
+ ### Changed
35
+ - No changes this release.
36
+
37
+ ## [0.29.0]
38
+ ### Changed
39
+ - **BREAKING:** Change checksum calculation ([#1128](https://github.com/MetaMask/snaps-monorepo/pull/1128))
40
+ - The checksum has changed for all snaps, and needs to be updated
41
+
42
+ ## [0.28.0]
43
+ ### Changed
44
+ - No changes this release.
45
+
46
+ ## [0.27.1]
47
+ ### Changed
48
+ - No changes this release.
49
+
50
+ ## [0.27.0]
51
+ ### Changed
52
+ - No changes this release.
53
+
54
+ ## [0.26.2]
55
+ ### Changed
56
+ - No changes this release.
57
+
58
+ ## [0.26.1]
59
+ ### Changed
60
+ - No changes this release.
61
+
62
+ ## [0.26.0]
63
+ ### Fixed
64
+ - Fix post processing issue with `object.eval` ([#1040](https://github.com/MetaMask/snaps-monorepo/pull/1040))
65
+
66
+ ## [0.25.0]
67
+ ### Changed
68
+ - No changes this release.
69
+
70
+ ## [0.24.1]
71
+ ### Changed
72
+ - No changes this release.
73
+
74
+ ## [0.24.0]
14
75
  ### Added
15
- - Add support for bundling with Webpack ([#1521](https://github.com/MetaMask/snaps/pull/1521))
16
- - For backwards compatibility, the Webpack bundler is opt-in. To use it, add
17
- `"bundler": "webpack"` to your snap configuration file, and follow the new
18
- configuration format described in the documentation.
19
- - The new configuration format also adds support for:
20
- - Setting environment variables, which are set as `process.env` values in
21
- the bundled code.
22
- - Importing WebAssembly modules (if `experimental.wasm` is enabled in the
23
- snap configuration file).
24
- - Support TypeScript snap configuration files ([#1521](https://github.com/MetaMask/snaps/pull/1521))
76
+ - Add permission validation to SnapManifest ([#910](https://github.com/MetaMask/snaps-monorepo/pull/910))
77
+
78
+ ### Fixed
79
+ - Remove double logging in CLI ([#958](https://github.com/MetaMask/snaps-monorepo/pull/958))
25
80
 
81
+ ## [0.23.0]
26
82
  ### Changed
27
- - Release package independently ([#1600](https://github.com/MetaMask/snaps/pull/1600))
28
- - The version of the package no longer needs to match the version of all other
29
- MetaMask Snaps packages.
83
+ - **BREAKING:** Refactor `mm-snap init` command ([#866](https://github.com/MetaMask/snaps-monorepo/pull/866))
84
+ - `mm-snap init` only takes one optional argument now, a directory for the snap to be initialized in.
85
+ - It uses a new snap monorepo template.
86
+ - Replace auto type guard with struct ([#911](https://github.com/MetaMask/snaps-monorepo/pull/911))
87
+ - Replace JSON schema validation with structs ([#862](https://github.com/MetaMask/snaps-monorepo/pull/862))
88
+
89
+ ## [0.22.3]
90
+ ### Changed
91
+ - No changes this release.
92
+
93
+ ## [0.22.2]
94
+ ### Changed
95
+ - No changes this release.
96
+
97
+ ## [0.22.1]
98
+ ### Changed
99
+ - No changes this release.
100
+
101
+ ## [0.22.0]
102
+ ### Changed
103
+ - No changes this release.
104
+
105
+ ## [0.21.0]
106
+ ### Changed
107
+ - No changes this release.
108
+
109
+ ## [0.20.0]
110
+ ### Changed
111
+ - No changes this release.
112
+
113
+ ## [0.19.1]
114
+ ### Fixed
115
+ - Fixed 0.19.0 not being able to run ([#697](https://github.com/MetaMask/snaps-monorepo/pull/697))
116
+
117
+ ## [0.19.0]
118
+ ### Added
119
+ - Add 'Access-Control-Allow-Origin': * to serve ([#638](https://github.com/MetaMask/snaps-monorepo/pull/638))
120
+
121
+ ### Changed
122
+ - **BREAKING:** Replace RegEx-based bundle processing and comment stripping with an AST-based solution ([#583](https://github.com/MetaMask/snaps-monorepo/pull/583))
123
+
124
+ ## [0.18.1]
125
+ ### Changed
126
+ - No changes this release.
127
+
128
+ ## [0.18.0]
129
+ ### Changed
130
+ - Reduce TypeScript compilation target to ES2017 ([#628](https://github.com/MetaMask/snaps-monorepo/pull/628))
131
+ - Update template files ([#632](https://github.com/MetaMask/snaps-monorepo/pull/632))
132
+
133
+ ## [0.17.0]
134
+ ### Added
135
+ - Add a TypeScript template for `mm-snap init` ([#546](https://github.com/MetaMask/snaps-monorepo/pull/546))
136
+ - Add serving to `mm-snap watch` ([#507](https://github.com/MetaMask/snaps-monorepo/pull/507))
137
+
138
+ ### Changed
139
+ - **BREAKING:** Bump minimum Node version to 16 ([#601](https://github.com/MetaMask/snaps-monorepo/pull/601))
140
+
141
+ ### Fixed
142
+ - Fix segfault when using `mm-snap watch` ([#556](https://github.com/MetaMask/snaps-monorepo/pull/556))
143
+
144
+ ## [0.16.0]
145
+ ### Changed
146
+ - **BREAKING:** Snaps are now required to export `onRpcRequest` to receive RPC requests ([#481](https://github.com/MetaMask/snaps-monorepo/pull/481), [#533](https://github.com/MetaMask/snaps-monorepo/pull/533), [#538](https://github.com/MetaMask/snaps-monorepo/pull/538), [#541](https://github.com/MetaMask/snaps-monorepo/pull/541), [#544](https://github.com/MetaMask/snaps-monorepo/pull/544))
147
+ - The type of the function is available in `@metamask/snaps-types` as `OnRpcRequestHandler`.
148
+
149
+ ### Fixed
150
+ - Fix importing local files in TypeScript Snaps ([#527](https://github.com/MetaMask/snaps-monorepo/pull/527))
151
+ - Fix `build` command when the CLI is installed globally ([#542](https://github.com/MetaMask/snaps-monorepo/pull/542))
152
+
153
+ ## [0.15.0]
154
+ ### Added
155
+ - Add support for building TypeScript Snaps ([#443](https://github.com/MetaMask/snaps-monorepo/pull/443))
156
+
157
+ ### Fixed
158
+ - Fix an issue where comment stripping would break for large files ([#468](https://github.com/MetaMask/snaps-monorepo/pull/468))
159
+
160
+ ## [0.14.0]
161
+ ### Changed
162
+ - **BREAKING:** Increase TypeScript compilation target to ES2020 ([#449](https://github.com/MetaMask/snaps-monorepo/pull/449))
163
+ - This should not be breaking for consumers on any non-deprecated browser or Node.js version.
164
+
165
+ ## [0.13.0]
166
+ ### Changed
167
+ - No changes this release.
168
+
169
+ ## [0.12.0]
170
+ ### Changed
171
+ - No changes this release.
172
+
173
+ ## [0.11.1]
174
+ ### Changed
175
+ - No changes this release.
176
+
177
+ ## [0.11.0]
178
+ ### Added
179
+ - Add self to mock endowments ([#341](https://github.com/MetaMask/snaps-monorepo/pull/341))
180
+
181
+ ### Changed
182
+ - Bump `ses` to `0.15.15` ([#396](https://github.com/MetaMask/snaps-monorepo/pull/396))
183
+ - Upgraded TypeScript version to minimum 4.4 ([#360](https://github.com/MetaMask/snaps-monorepo/pull/360))
184
+ - Update template files ([#350](https://github.com/MetaMask/snaps-monorepo/pull/350))
185
+
186
+ ## [0.10.7]
187
+ ### Changed
188
+ - **BREAKING:** Bump minimum Node version from 12 to 14 ([#331](https://github.com/MetaMask/snaps-monorepo/pull/331))
189
+ - Update `mm-snap init` template files ([#330](https://github.com/MetaMask/snaps-monorepo/pull/330))
190
+
191
+ ### Fixed
192
+ - Fix issue where comment stripping would create invalid bundles ([#336](https://github.com/MetaMask/snaps-monorepo/pull/336))
193
+
194
+ ## [0.10.6]
195
+ ### Fixed
196
+ - Fix endowment mocking during `mm-snap eval` ([#311](https://github.com/MetaMask/snaps-monorepo/pull/311))
197
+
198
+ ## [0.10.5]
199
+ ### Changed
200
+ - No changes this release.
201
+
202
+ ## [0.10.3]
203
+ ### Fixed
204
+ - Improve dynamic mocking ([#262](https://github.com/MetaMask/snaps-monorepo/pull/262))
205
+
206
+ ## [0.10.2]
207
+ ### Fixed
208
+ - Installation failure ([#279](https://github.com/MetaMask/snaps-monorepo/pull/279))
209
+ - A faulty installation script in a dependency caused the installation of this package to fail.
210
+
211
+ ## [0.10.1]
212
+ ### Fixed
213
+ - Comment stripping will no longer remove empty block comments in strings ([#276](https://github.com/MetaMask/snaps-monorepo/pull/276))
214
+
215
+ ## [0.10.0]
216
+ ### Added
217
+ - **BREAKING:** Transform HTML comments by default ([#237](https://github.com/MetaMask/snaps-monorepo/pull/237))
218
+ - The strings `<!--` and `-->` will be transformed into `< !--` and `-- >` respectively by default. If these strings appear as operands in an expression or in a string literal, this transform will change the behavior of your program. This behavior was added because these strings are rejected by SES. The behavior can be toggled using the `--transformHtmlComments` option.
219
+ - `--transpiledDeps` flag to `build` and `watch` commands ([#221](https://github.com/MetaMask/snaps-monorepo/pull/221))
220
+ - This flag allows the user to specify which dependencies will be transpiled at build time if the `--transpilationMode` is `--localAndDeps`.
221
+ - Add CLI usage instructions to readme ([#228](https://github.com/MetaMask/snaps-monorepo/pull/228))
222
+ - Build process customization ([#251](https://github.com/MetaMask/snaps-monorepo/pull/251))
223
+ - Builds can now be customized by adding a `bundlerCustomizer` function to `snap.config.js`. See the README for details.
224
+
225
+ ### Changed
226
+ - **BREAKING:** Change Snap config file format ([#251](https://github.com/MetaMask/snaps-monorepo/pull/251))
227
+ - The CLI now expects a file `snap.config.js` instead of `snap.config.json`, with a different structure. See the README for details.
228
+ - **BREAKING:** Strip comments in source code by default ([#243](https://github.com/MetaMask/snaps-monorepo/pull/243))
229
+ - All comments will now be stripped from snap source code (including dependencies) by default.
230
+ - Enable `--verboseErrors` by default ([#249](https://github.com/MetaMask/snaps-monorepo/pull/249))
231
+
232
+ ### Fixed
233
+ - Comment stripping bug ([#270](https://github.com/MetaMask/snaps-monorepo/pull/270))
234
+ - Prior to this change, if the `--strip-comments` option was provided to `mm-snap build` and an empty block comment of the form `/**/` appeared anywhere in the source code (including dependencies), the remainder of the string after the empty block comment would be truncated. This was resolved by removing all instances of the string `/**/` from the raw bundle string.
235
+ - In an upcoming release, the string `/**/` will only be removed if it is in fact an empty block comment, and not if it e.g. appears in a string literal.
236
+ - `watch` command parity with `build` command ([#241](https://github.com/MetaMask/snaps-monorepo/pull/241))
237
+ - The `build` command had received a number of options that were not made available to the `watch` command. They now have the same options.
238
+ - Update dead link in readme ([#240](https://github.com/MetaMask/snaps-monorepo/pull/240))
239
+
240
+ ## [0.9.0]
241
+ ### Added
242
+ - Transpilation configuration ([#213](https://github.com/MetaMask/snaps-monorepo/pull/213))
243
+ - `mm-snap build` now takes a `--transpilationMode` argument which determines what will be transpiled by Babel during building: all source code (including dependencies), local source code only, or nothing.
244
+
245
+ ### Fixed
246
+ - `mm-snap build` command when CLI is installed globally ([#216](https://github.com/MetaMask/snaps-monorepo/pull/216))
247
+ - Update installation command in readme ([#205](https://github.com/MetaMask/snaps-monorepo/pull/205))
248
+
249
+ ## [0.8.0]
250
+ ### Changed
251
+ - Update template snap created by `mm-snap init` ([#195](https://github.com/MetaMask/snaps-monorepo/pull/195))
252
+ - Exit by throwing errors instead of calling `process.exit` ([#190](https://github.com/MetaMask/snaps-monorepo/pull/190))
253
+
254
+ ## [0.7.0]
255
+ ### Added
256
+ - ESM support for `mm-snap build` ([#185](https://github.com/MetaMask/snaps-monorepo/pull/185))
257
+ - The `build` command can now handle snap source code that includes ESM import / export statements. They will be transpiled to their CommonJS equivalents via Babel.
258
+
259
+ ### Fixed
260
+ - Fix `mm-snap init` `src` default value ([#186](https://github.com/MetaMask/snaps-monorepo/pull/186))
261
+ - It now correctly defaults to `src/index.js` instead of just `index.js`.
262
+ - Fix comment stripping ([#189](https://github.com/MetaMask/snaps-monorepo/pull/189))
263
+ - Comments wouldn't be stripped under certain circumstances due to a RegEx error, details [here](https://github.com/jonschlinkert/strip-comments/pull/49).
264
+
265
+ ## [0.6.3]
266
+ ### Changed
267
+ - No changes this release.
268
+
269
+ ## [0.6.2]
270
+ ### Changed
271
+ - No changes this release.
272
+
273
+ ## [0.6.1]
274
+ ### Fixed
275
+ - `mm-snap init` Snap `snap_confirm` call ([#168](https://github.com/MetaMask/snaps-monorepo/pull/168))
276
+ - The generated Snap was passing invalid parameters to the method.
277
+
278
+ ## [0.6.0]
279
+ ### Added
280
+ - Snap SVG icon support ([#163](https://github.com/MetaMask/snaps-monorepo/pull/163))
281
+
282
+ ### Changed
283
+ - **BREAKING:** Support the new Snaps publishing specification ([#140](https://github.com/MetaMask/snaps-monorepo/pull/140), [#160](https://github.com/MetaMask/snaps-monorepo/pull/160))
284
+ - This introduces several breaking changes to how Snaps are developed, hosted, and represented at runtime. See [the specification](https://github.com/MetaMask/specifications/blob/d4a5bf5d6990bb5b02a98bd3f95a24ffb28c701c/snaps/publishing.md) and the referenced pull requests for details.
285
+ - **BREAKING:** Rename Snap `name` property to `id` ([#147](https://github.com/MetaMask/snaps-monorepo/pull/147))
286
+ - **BREAKING:** Update `ses` to version `^0.15.3` ([#159](https://github.com/MetaMask/snaps-monorepo/pull/159))
287
+ - This will cause behavioral changes for code executed under SES, and may require modifications to code that previously executed without issues.
288
+
289
+ ## [0.5.0]
290
+ ### Changed
291
+ - **BREAKING:** Convert all TypeScript `interface` declarations to `type` equivalents ([#143](https://github.com/MetaMask/snaps-monorepo/pull/143))
292
+
293
+ ## [0.4.0]
294
+ ### Fixed
295
+ - Make Windows-compatible ([#131](https://github.com/MetaMask/snaps-monorepo/pull/131))
296
+
297
+ ## [0.3.1]
298
+ ### Changed
299
+ - No changes this release.
300
+
301
+ ## [0.3.0]
302
+ ### Changed
303
+ - **BREAKING:** Enforce consistent naming for Snaps-related functionality ([#119](https://github.com/MetaMask/snaps-monorepo/pull/119))
304
+
305
+ ## [0.2.2]
306
+ ### Fixed
307
+ - Package script issues ([#97](https://github.com/MetaMask/snaps-monorepo/pull/97), [#98](https://github.com/MetaMask/snaps-monorepo/pull/98))
308
+
309
+ ## [0.2.1]
310
+ ### Fixed
311
+ - Snap produced by `mm-snap init` ([#94](https://github.com/MetaMask/snaps-monorepo/pull/94))
312
+ - The template used to create the "Hello, world!" snap had become outdated due to a build-time bug.
313
+
314
+ ## [0.2.0]
315
+ ### Changed
316
+ - Update publish scripts ([#92](https://github.com/MetaMask/snaps-monorepo/pull/92))
317
+
318
+ ## [0.1.1]
319
+ ### Added
320
+ - Missing publish scripts to new packages
321
+
322
+ ## [0.1.0]
323
+ ### Changed
324
+ - **BREAKING:** Rename package to `@metamask/snaps-cli` ([#72](https://github.com/MetaMask/snaps-monorepo/pull/72))
325
+ - This package was previously named [`snaps-cli`](https://npmjs.com/package/snaps-cli).
326
+ - As part of the renaming, and due to the scope of the changes to both this package and MetaMask Snaps generally, its versioning and changelog have been reset. The original changelog can be found [here](https://github.com/MetaMask/snaps-cli/blob/main/CHANGELOG.md).
327
+
328
+ ### Removed
329
+ - Example snaps ([#72](https://github.com/MetaMask/snaps-monorepo/pull/72))
330
+ - The examples now live in their own package, [`@metamask/snap-examples`](https://npmjs.com/package/@metamask/snap-examples).
30
331
 
31
- [Unreleased]: https://github.com/MetaMask/snaps/compare/@metamask/snaps-cli@0.38.1-flask.1...HEAD
32
- [0.38.1-flask.1]: https://github.com/MetaMask/snaps/compare/@metamask/snaps-cli@0.38.0-flask.1...@metamask/snaps-cli@0.38.1-flask.1
33
- [0.38.0-flask.1]: https://github.com/MetaMask/snaps/releases/tag/@metamask/snaps-cli@0.38.0-flask.1
332
+ [Unreleased]: https://github.com/MetaMask/snaps/compare/v1.0.0...HEAD
333
+ [1.0.0]: https://github.com/MetaMask/snaps/compare/v1.0.0-prerelease.1...v1.0.0
334
+ [1.0.0-prerelease.1]: https://github.com/MetaMask/snaps/compare/v0.32.2...v1.0.0-prerelease.1
335
+ [0.32.2]: https://github.com/MetaMask/snaps/compare/v0.32.1...v0.32.2
336
+ [0.32.1]: https://github.com/MetaMask/snaps/compare/v0.32.0...v0.32.1
337
+ [0.32.0]: https://github.com/MetaMask/snaps/compare/v0.31.0...v0.32.0
338
+ [0.31.0]: https://github.com/MetaMask/snaps/compare/v0.30.0...v0.31.0
339
+ [0.30.0]: https://github.com/MetaMask/snaps/compare/v0.29.0...v0.30.0
340
+ [0.29.0]: https://github.com/MetaMask/snaps/compare/v0.28.0...v0.29.0
341
+ [0.28.0]: https://github.com/MetaMask/snaps/compare/v0.27.1...v0.28.0
342
+ [0.27.1]: https://github.com/MetaMask/snaps/compare/v0.27.0...v0.27.1
343
+ [0.27.0]: https://github.com/MetaMask/snaps/compare/v0.26.2...v0.27.0
344
+ [0.26.2]: https://github.com/MetaMask/snaps/compare/v0.26.1...v0.26.2
345
+ [0.26.1]: https://github.com/MetaMask/snaps/compare/v0.26.0...v0.26.1
346
+ [0.26.0]: https://github.com/MetaMask/snaps/compare/v0.25.0...v0.26.0
347
+ [0.25.0]: https://github.com/MetaMask/snaps/compare/v0.24.1...v0.25.0
348
+ [0.24.1]: https://github.com/MetaMask/snaps/compare/v0.24.0...v0.24.1
349
+ [0.24.0]: https://github.com/MetaMask/snaps/compare/v0.23.0...v0.24.0
350
+ [0.23.0]: https://github.com/MetaMask/snaps/compare/v0.22.3...v0.23.0
351
+ [0.22.3]: https://github.com/MetaMask/snaps/compare/v0.22.2...v0.22.3
352
+ [0.22.2]: https://github.com/MetaMask/snaps/compare/v0.22.1...v0.22.2
353
+ [0.22.1]: https://github.com/MetaMask/snaps/compare/v0.22.0...v0.22.1
354
+ [0.22.0]: https://github.com/MetaMask/snaps/compare/v0.21.0...v0.22.0
355
+ [0.21.0]: https://github.com/MetaMask/snaps/compare/v0.20.0...v0.21.0
356
+ [0.20.0]: https://github.com/MetaMask/snaps/compare/v0.19.1...v0.20.0
357
+ [0.19.1]: https://github.com/MetaMask/snaps/compare/v0.19.0...v0.19.1
358
+ [0.19.0]: https://github.com/MetaMask/snaps/compare/v0.18.1...v0.19.0
359
+ [0.18.1]: https://github.com/MetaMask/snaps/compare/v0.18.0...v0.18.1
360
+ [0.18.0]: https://github.com/MetaMask/snaps/compare/v0.17.0...v0.18.0
361
+ [0.17.0]: https://github.com/MetaMask/snaps/compare/v0.16.0...v0.17.0
362
+ [0.16.0]: https://github.com/MetaMask/snaps/compare/v0.15.0...v0.16.0
363
+ [0.15.0]: https://github.com/MetaMask/snaps/compare/v0.14.0...v0.15.0
364
+ [0.14.0]: https://github.com/MetaMask/snaps/compare/v0.13.0...v0.14.0
365
+ [0.13.0]: https://github.com/MetaMask/snaps/compare/v0.12.0...v0.13.0
366
+ [0.12.0]: https://github.com/MetaMask/snaps/compare/v0.11.1...v0.12.0
367
+ [0.11.1]: https://github.com/MetaMask/snaps/compare/v0.11.0...v0.11.1
368
+ [0.11.0]: https://github.com/MetaMask/snaps/compare/v0.10.7...v0.11.0
369
+ [0.10.7]: https://github.com/MetaMask/snaps/compare/v0.10.6...v0.10.7
370
+ [0.10.6]: https://github.com/MetaMask/snaps/compare/v0.10.5...v0.10.6
371
+ [0.10.5]: https://github.com/MetaMask/snaps/compare/v0.10.3...v0.10.5
372
+ [0.10.3]: https://github.com/MetaMask/snaps/compare/v0.10.2...v0.10.3
373
+ [0.10.2]: https://github.com/MetaMask/snaps/compare/v0.10.1...v0.10.2
374
+ [0.10.1]: https://github.com/MetaMask/snaps/compare/v0.10.0...v0.10.1
375
+ [0.10.0]: https://github.com/MetaMask/snaps/compare/v0.9.0...v0.10.0
376
+ [0.9.0]: https://github.com/MetaMask/snaps/compare/v0.8.0...v0.9.0
377
+ [0.8.0]: https://github.com/MetaMask/snaps/compare/v0.7.0...v0.8.0
378
+ [0.7.0]: https://github.com/MetaMask/snaps/compare/v0.6.3...v0.7.0
379
+ [0.6.3]: https://github.com/MetaMask/snaps/compare/v0.6.2...v0.6.3
380
+ [0.6.2]: https://github.com/MetaMask/snaps/compare/v0.6.1...v0.6.2
381
+ [0.6.1]: https://github.com/MetaMask/snaps/compare/v0.6.0...v0.6.1
382
+ [0.6.0]: https://github.com/MetaMask/snaps/compare/v0.5.0...v0.6.0
383
+ [0.5.0]: https://github.com/MetaMask/snaps/compare/v0.4.0...v0.5.0
384
+ [0.4.0]: https://github.com/MetaMask/snaps/compare/v0.3.1...v0.4.0
385
+ [0.3.1]: https://github.com/MetaMask/snaps/compare/v0.3.0...v0.3.1
386
+ [0.3.0]: https://github.com/MetaMask/snaps/compare/v0.2.2...v0.3.0
387
+ [0.2.2]: https://github.com/MetaMask/snaps/compare/v0.2.1...v0.2.2
388
+ [0.2.1]: https://github.com/MetaMask/snaps/compare/v0.2.0...v0.2.1
389
+ [0.2.0]: https://github.com/MetaMask/snaps/compare/v0.1.1...v0.2.0
390
+ [0.1.1]: https://github.com/MetaMask/snaps/compare/v0.1.0...v0.1.1
391
+ [0.1.0]: https://github.com/MetaMask/snaps/releases/tag/v0.1.0