forked from fable-compiler/ts2fable
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fable-compiler#428, fable-compiler#429 --noresizearray, --convertpropfns
- Loading branch information
1 parent
5af1560
commit 4525ea2
Showing
12 changed files
with
230 additions
and
103 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
module Config | ||
|
||
let mutable EmitResizeArray = true | ||
let mutable ConvertPropertyFunctions = false | ||
|
||
let Reset() = | ||
EmitResizeArray <- true | ||
ConvertPropertyFunctions <- false | ||
|
||
module OptionNames = | ||
let NoEmitResizeArray = "--noresizearray" | ||
let ConvertPropertyFunctions = "--convertpropfns" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
//--noresizearray | ||
declare class Appwrite { | ||
account: { | ||
createDocument: string[] | ||
}; | ||
} | ||
export { Appwrite }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
// ts2fable 0.0.0 | ||
module rec ``#428-noresizearray`` | ||
open System | ||
open Fable.Core | ||
open Fable.Core.JS | ||
|
||
|
||
type [<AllowNullLiteral>] IExports = | ||
abstract Appwrite: AppwriteStatic | ||
|
||
type [<AllowNullLiteral>] Appwrite = | ||
abstract account: AppwriteAccount with get, set | ||
|
||
type [<AllowNullLiteral>] AppwriteStatic = | ||
[<EmitConstructor>] abstract Create: unit -> Appwrite | ||
|
||
type [<AllowNullLiteral>] AppwriteAccount = | ||
abstract createDocument: string[] with get, set |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
//--convertpropfns | ||
declare class Appwrite { | ||
account: { | ||
createDocument: (name: string) => Document; | ||
}; | ||
} | ||
export { Appwrite }; |
18 changes: 18 additions & 0 deletions
18
test/fragments/regressions/#429-convertpropfns.expected.fs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
// ts2fable 0.8.0 | ||
module rec ``#429-convertpropfns`` | ||
open System | ||
open Fable.Core | ||
open Fable.Core.JS | ||
|
||
|
||
type [<AllowNullLiteral>] IExports = | ||
abstract Appwrite: AppwriteStatic | ||
|
||
type [<AllowNullLiteral>] Appwrite = | ||
abstract account: AppwriteAccount with get, set | ||
|
||
type [<AllowNullLiteral>] AppwriteStatic = | ||
[<EmitConstructor>] abstract Create: unit -> Appwrite | ||
|
||
type [<AllowNullLiteral>] AppwriteAccount = | ||
abstract createDocument: name: string -> Document |
Oops, something went wrong.