Skip to content

Migration code breaks React Native Hermes bundle due to unsupported dynamic import #1628

@bviebahn

Description

@bviebahn

When using Kysely in an Expo / React Native project, even without using migrations, Hermes fails to bundle because the migration provider includes a computed dynamic import. Since this code is included in the main export bundle, it’s parsed even if unused.

❌ (/Users/expo/Library/Developer/Xcode/DerivedData/mobile-buyqshytqhqhjxgzhdwtlgltoake/Build/Intermediates.noindex/ArchiveIntermediates/mobile/BuildProductsPath/Release-iphoneos/main.jsbundle:298184:37) ...ield import(/* webpackIgnore: true */(0, _classPrivateFieldLooseBase2.default)(this, _props)[_props].path.join((0, _classPrivateFieldLooseBase2.default)(this, _props)[_props].migrationF... ^ Invalid expression encountered

This seems to be the same issue: #751

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions