Skip to content

[Request]: make toMap() json compatible #949

Description

@iapicca

Plugin

device_info_plus

Use case

renaming toMap() as toJson would improve compatibility with dart:convert
see referece at https://api.dart.dev/be/175791/dart-convert/jsonEncode.html

If toEncodable is omitted, it defaults to a function that returns the result of calling .toJson() on the unencodable object.

Proposal

rename BaseDeviceInfo method toMap() as toJson() and to all overrides across the package

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions