@quenty/valueobject 8.4.0 → 9.0.0-canary.439.eb597ee.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.
- package/CHANGELOG.md +8 -0
- package/package.json +9 -8
- package/src/Shared/ValueObject.lua +5 -4
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,14 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# [9.0.0-canary.439.eb597ee.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/valueobject@8.4.0...@quenty/valueobject@9.0.0-canary.439.eb597ee.0) (2024-01-17)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @quenty/valueobject
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
6
14
|
# [8.4.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/valueobject@8.3.0...@quenty/valueobject@8.4.0) (2024-01-08)
|
|
7
15
|
|
|
8
16
|
**Note:** Version bump only for package @quenty/valueobject
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@quenty/valueobject",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "9.0.0-canary.439.eb597ee.0",
|
|
4
4
|
"description": "To work like value objects in Roblox and track a single item with .Changed events",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Roblox",
|
|
@@ -26,15 +26,16 @@
|
|
|
26
26
|
"Quenty"
|
|
27
27
|
],
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@quenty/brio": "
|
|
30
|
-
"@quenty/
|
|
31
|
-
"@quenty/
|
|
32
|
-
"@quenty/
|
|
33
|
-
"@quenty/
|
|
34
|
-
"@quenty/
|
|
29
|
+
"@quenty/brio": "10.0.0-canary.439.eb597ee.0",
|
|
30
|
+
"@quenty/ducktype": "3.0.0-canary.439.eb597ee.0",
|
|
31
|
+
"@quenty/loader": "8.0.0-canary.439.eb597ee.0",
|
|
32
|
+
"@quenty/maid": "2.6.0",
|
|
33
|
+
"@quenty/rx": "9.0.0-canary.439.eb597ee.0",
|
|
34
|
+
"@quenty/signal": "4.0.0-canary.439.eb597ee.0",
|
|
35
|
+
"@quenty/valuebaseutils": "9.0.0-canary.439.eb597ee.0"
|
|
35
36
|
},
|
|
36
37
|
"publishConfig": {
|
|
37
38
|
"access": "public"
|
|
38
39
|
},
|
|
39
|
-
"gitHead": "
|
|
40
|
+
"gitHead": "eb597ee01e62e4dd91190bb7abd1d1404652d5ff"
|
|
40
41
|
}
|
|
@@ -12,6 +12,7 @@ local Observable = require("Observable")
|
|
|
12
12
|
local ValueBaseUtils = require("ValueBaseUtils")
|
|
13
13
|
local RxValueBaseUtils = require("RxValueBaseUtils")
|
|
14
14
|
local Brio = require("Brio")
|
|
15
|
+
local DuckTypeUtils = require("DuckTypeUtils")
|
|
15
16
|
|
|
16
17
|
local EMPTY_FUNCTION = function() end
|
|
17
18
|
|
|
@@ -75,7 +76,7 @@ end
|
|
|
75
76
|
@return boolean
|
|
76
77
|
]=]
|
|
77
78
|
function ValueObject.isValueObject(value)
|
|
78
|
-
return
|
|
79
|
+
return DuckTypeUtils.isImplementation(ValueObject, value)
|
|
79
80
|
end
|
|
80
81
|
|
|
81
82
|
function ValueObject:_toMountableObservable(value)
|
|
@@ -269,7 +270,7 @@ function ValueObject:__index(index)
|
|
|
269
270
|
elseif index == "_value" then
|
|
270
271
|
return nil -- Edge case
|
|
271
272
|
else
|
|
272
|
-
error(("%q is not a member of ValueObject"
|
|
273
|
+
error(string.format("%q is not a member of ValueObject", tostring(index)))
|
|
273
274
|
end
|
|
274
275
|
end
|
|
275
276
|
|
|
@@ -278,9 +279,9 @@ function ValueObject:__newindex(index, value)
|
|
|
278
279
|
-- Avoid deoptimization
|
|
279
280
|
ValueObject.SetValue(self, value)
|
|
280
281
|
elseif index == "LastEventContext" or ValueObject[index] then
|
|
281
|
-
error(("%q cannot be set in ValueObject"
|
|
282
|
+
error(string.format("%q cannot be set in ValueObject", tostring(index)))
|
|
282
283
|
else
|
|
283
|
-
error(("%q is not a member of ValueObject"
|
|
284
|
+
error(string.format("%q is not a member of ValueObject", tostring(index)))
|
|
284
285
|
end
|
|
285
286
|
end
|
|
286
287
|
|