Coder Social home page Coder Social logo

Comments (7)

alextekartik avatar alextekartik commented on July 30, 2024 1

Sorry it seems I messed up basic web workers. Can you try to update to sqflite_common_ffi_web 0.4.3+1 just published?

Need to re-run:

$ dart run sqflite_common_ffi_web:setup --force

https://tk-demo-sqflite.web.app/

from sqflite.

DDSrivatsan avatar DDSrivatsan commented on July 30, 2024

@alextekartik Thank you for Updating... Will update the package and let within a day or two..

from sqflite.

DDSrivatsan avatar DDSrivatsan commented on July 30, 2024

@alextekartik Thanks for updating the package now its working fine in both android and windows. One more thing need to clarify how to overcome this error in console.

*** sqflite warning ***

You are changing sqflite default factory.
Be aware of the potential side effects. Any library using sqflite
will have this factory as the default for all operations.

*** sqflite warning ***
if (kIsWeb) { 
// Change default factory on the web 
sql.databaseFactory = databaseFactoryFfiWeb; 
databaseFactoryOrNull = databaseFactoryFfiWeb; // Should I Add like this how to do it ?
dbPath = 'ultimate.db'; 
} 

Kindly clarify, thank you in advance,

from sqflite.

DDSrivatsan avatar DDSrivatsan commented on July 30, 2024

@alextekartik

im using like this is the correct ? Kindly let me know

import 'package:sqflite_common_ffi_web/sqflite_ffi_web.dart';
import 'package:sqflite/sqflite.dart' as sql;

if (kIsWeb) {
      // Change default factory on the web
      sql.databaseFactoryOrNull=null;
      sql.databaseFactory = databaseFactoryFfiWeb;
      dbPath = 'ultimate.db';
    }

from sqflite.

alextekartik avatar alextekartik commented on July 30, 2024

Simply do:

import 'package:sqflite_common_ffi_web/sqflite_ffi_web.dart';
import 'package:sqflite/sqflite.dart' as sql;

if (kIsWeb) {
  // Change default factory on the web
  sql.databaseFactoryOrNull = databaseFactoryFfiWeb;
  dbPath = 'ultimate.db';
}

from sqflite.

DDSrivatsan avatar DDSrivatsan commented on July 30, 2024

thank you @alextekartik . Opened issue is also fixed can i close the issue ?

from sqflite.

alextekartik avatar alextekartik commented on July 30, 2024

@DDSrivatsan Yes typically I let the person that created the issue closing it (otherwise I'll do it later). Thank you !

from sqflite.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.