5
0
mirror of https://github.com/wailsapp/wails.git synced 2025-05-02 19:31:20 +08:00
Commit Graph

9 Commits

Author SHA1 Message Date
Jeremy Jay
c4fdfd6415
Fix miscellaneous bindings and typescript export bugs (#3978)
* Do not attempt to export fields that cannot be json-encoded

* update changelog w/ PR

* also skip UnsafePointers

* WIP to allow conversion from Go generic types to typescript

* support for non-primitive generics also :)

* fix generic types in parameters / return args

* fixes a namespacing bug when mapping to pointer to struct

* fixing invalid knownstructs

* found a place it mattered, pushing the star replacement to the generate side

* descend as much as necessary to find structs

caught these examples in http.Request.TLS:

PeerCertificates []*x509.Certificate
VerifiedChains [][]*x509.Certificate

* accidently reverted other fix

* switch syntax for typescript record outputs

prior syntax is primarily useful for naming keys
so not useful here, and this syntax avoids square
brackets in output which greatly simplifies
generation for Go generics

* better handle edge cases for nested arrays and slices

* lots o tests

* update changelog

---------

Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2025-01-13 20:14:54 +11:00
Andrey Pshenkin
b9de31e38e
Add support for interface generation and enums (#3047)
* Add support to output ts models as interfaces

* Add support to generate enums from golang

* cleanup logs

* add missing documentation

* fix package names for enum. Fix processing enums that are in separate packages

* revert golang 1.21

* Fix spelling

* Add support for simplified version of Enum for typescriptify

* update docs

* removed unused logs

* Add tests. Fix imported enums types in models

---------

Co-authored-by: Lea Anthony <lea.anthony@gmail.com>
2023-11-26 06:50:49 +11:00
Lea Anthony
052b9222c1
Add garble support (#1793)
Co-authored-by: AlbinoDrought <sean@albinodrought.com>
Co-authored-by: stffabi <stffabi@users.noreply.github.com>
2022-09-13 10:05:37 +10:00
Valentin Trinqué
cf3c65f0cc
Fix registration of exposed fields (#1727) 2022-08-11 08:41:37 +10:00
Lea Anthony
d4662bd797
Support Maps in TS conversion (#1435) 2022-07-10 20:54:49 +10:00
Ariel
9097c9086b
import models on binding definition (#1231) 2022-03-09 07:44:32 +11:00
Albert Sun
f5c3907fac added interface{} test case and fixed 2022-01-22 10:23:02 -05:00
Albert Sun
4118f348f5 fixed generate test 2022-01-22 00:59:26 -05:00
Alexander Hudek
0966c96ef0
Fixed generated typescript type for []byte. (#701) 2021-05-02 13:08:49 +10:00