Uploaded image for project: 'Realm Dart SDK'
  1. Realm Dart SDK
  2. RDART-991

Ejson uses the name Key which is a name used in flutter foundation

      Problem

      Today I updated to realm 2.0, but I got such error after update:

      The name 'Key' is defined in the libraries 'package:ejson/src/types.dart' and 'package:flutter/src/foundation/key.dart'.  
      Try using 'as prefix' for one of the import directives, or hiding the name from all but one of the imports.
      

      Solution

      So I need to import 'package:realm/realm.dart' as realm; to overcome this in pages that uses Key from flutter sdk, as I did not manually import ejson but realm imports that.

      I believe there are better ways to implement ejson to avoid this.

      Thanks again for your splendid work and your time!

      Alternatives

      No response

      How important is this improvement for you?

      I would like to have it but have a workaround

      Feature would mainly be used with

      Atlas Device Sync

            Assignee:
            kasper.nielsen@mongodb.com Kasper Nielsen
            Reporter:
            unitosyncbot Unito Sync Bot
            AD SDK Team 2
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: