Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Add JSBridgedType and JSBridgedClass #26

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
j-f1 merged 26 commits into swiftwasm:master from j-f1:webidl
Sep 18, 2020
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
b123600
Changes related to WebIDL support.
mjburghard Jun 7, 2020
e6b6705
Rename constructor
j-f1 Aug 2, 2020
5982bef
wip
j-f1 Aug 3, 2020
a5ce5e4
Add JSAbstractBridgedType
j-f1 Aug 4, 2020
0f79f43
More updates
j-f1 Aug 4, 2020
fbf9f76
Move & rename JS*BridgedType
j-f1 Aug 14, 2020
e31a989
wip
j-f1 Aug 14, 2020
e4d657e
Update JSTypedArray.swift
j-f1 Aug 14, 2020
c07db3d
Update JSTypedArray.swift
j-f1 Aug 14, 2020
be1f916
Update JSTypedArray.swift
j-f1 Aug 14, 2020
ba3316e
Update JSTypedArray.swift
j-f1 Aug 14, 2020
5fe4b96
Allow JSBridgedType (but not JSBridgedClass) to hold non-objects
j-f1 Aug 14, 2020
b62b78e
Make JS{Array,Date,Error} conform to JSBridgedClass
j-f1 Sep 15, 2020
8b181c7
Clean up AnyJSValueConvertible
j-f1 Sep 15, 2020
de5f52e
Docs for JSTypedArray
j-f1 Sep 15, 2020
479ad20
Docs for JSValueCoable-adjacent types
j-f1 Sep 15, 2020
b4edc19
Update based on review suggestions
j-f1 Sep 16, 2020
cabda58
Remove AnyJSValueConvertible
j-f1 Sep 16, 2020
d0da61a
Merge branch 'master' into webidl
j-f1 Sep 16, 2020
e19788a
Remove is* helpers
j-f1 Sep 16, 2020
ff1f4ac
withCompatibleObject → unsafelyWrapping
j-f1 Sep 17, 2020
c74e3d1
Apply suggestions from code review
j-f1 Sep 17, 2020
ed9f8d4
Rename Object and Array constructors
j-f1 Sep 17, 2020
29a30e7
Document & fix the behavior of isInstanceOf
j-f1 Sep 17, 2020
4429d88
Merge branch 'master' into webidl
j-f1 Sep 17, 2020
767d05d
Fix indent
j-f1 Sep 18, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Apply suggestions from code review
Co-authored-by: Max Desiatov <max@desiatov.com>
  • Loading branch information
j-f1 and MaxDesiatov authored Sep 17, 2020
commit c74e3d1cdd8b6a8fa7d2bada0eecdc9416b5aadf
4 changes: 2 additions & 2 deletions Sources/JavaScriptKit/BasicObjects/JSArray.swift
View file Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ extension JSArray: RandomAccessCollection {
}

public class Iterator: IteratorProtocol {
let jsObject: JSObject
var index = 0
private let jsObject: JSObject
private var index = 0
init(jsObject: JSObject) {
self.jsObject = jsObject
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/JavaScriptKit/JSBridgedType.swift
View file Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public protocol JSBridgedClass: JSBridgedType {
static var constructor: JSFunction { get }

/// The JavaScript object wrapped by this instance.
/// You may assume that `jsObject instanceof Self.constructor`
/// You may assume that `jsObject instanceof Self.constructor == true`
var jsObject: JSObject { get }

/// Create an instannce wrapping the given JavaScript object.
Expand Down
2 changes: 1 addition & 1 deletion Sources/JavaScriptKit/JSValueConvertible.swift
View file Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,6 @@ extension Array where Element == JSValueConvertible {

extension Array where Element: JSValueConvertible {
func withRawJSValues<T>(_ body: ([RawJSValue]) -> T) -> T {
Array<JSValueConvertible>.withRawJSValues(self)(body)
[JSValueConvertible].withRawJSValues(self)(body)
}
}

AltStyle によって変換されたページ (->オリジナル) /