/ionic-angular-sqlite

:clipboard: App to store data using the Ionic framework, cordova SQLite database, cordova SQLite Porter and Capacitor.

Primary LanguageTypeScriptMIT LicenseMIT

Ionic Angular SQLite

GitHub repo size GitHub pull requests GitHub Repo stars GitHub last commit

Table of contents

General info

  • App allows user to add details of developer and products.
  • Initial seed data is a short list of developers and dev skills.

Screenshots

example screen print example screen print

Technologies

Setup

  • Run npm i to install dependencies
  • To start the server on localhost://8100 type: 'ionic serve'

Code Examples

  • database.service.ts function to get details of a developer from the database that return a promise of format Dev
getDeveloper(id): Promise<Dev> {
  return this.database.executeSql('SELECT * FROM developer WHERE id = ?', [id]).then(data => {
    let skills = [];
    if (data.rows.item[0].skills !== '') {
      skills = JSON.parse(data.rows.item[0].skills);
    }

    return {
      id: data.rows.item(0).is,
      name: data.rows.item(0).name,
      skills,
      img: data.rows.item[0].img
    };
  });
}

Features

  • storage of data in an SQL database.

Status & To-do list

  • Status: compiles and displays in a dev server. Build webpacks created. Needs implementing on an Android device or simulator to use database etc. Database side not tested.
  • To-do: test database to see if it stores Dev and Product details.

Inspiration

📁 License

  • This project is licensed under the terms of the MIT license.

✉️ Contact