Git Product home page Git Product logo

freestyle-kv's Introduction

Open Freestyle.sh

freestyle-astro-template

Open in StackBlitz

freestyle.sh is a cloud platform in early development that replaces traditional databases with persistent javascript objects. Write code as if your data is in memory and never think about it's underlying storage mechanisms again. We'll statically and dynamically optimize your code to make efficient queries inside our cloudstate environment.

// The @cloudstate decorator makes this class's data persistent.
// Data can only be augmented and retrieved through the class's
// methods. There's nothing you have to do for your data to be
// saved, it's automatically saved for you.
@cloudstate
class Counter {
  count = 0;
  increment() {
    this.count++;
  }
  getCount() {
    return this.count;
  }
}

// Creates a singleton instance of Counter if one doesn't exist
// and returns an async wrapper around it. Your methods are executed
// and optimized inside your cloudstate database, not in your web server.
const counter = useCloudState(Counter);

// Call a method on counter from anywhere in your backend code
// to execute the method on the database. Calling authenticated
// methods from frontend coming soon.
await counter.increment();

Astro is the web framework for building content-driven websites like blogs, marketing, and e-commerce. To learn more, visit their documentation

Developing Locally

Please note that cloudstate is not persistent during local development.

install dependencies

npm i

run the development server

npm run dev

Ready to Deploy

build your project

npm run build

log into freestyle using github

npx freestyle-sh@latest login

deploy to freestyle.sh (beta)

npx freestyle-sh@latest deploy

freestyle-kv's People

Contributors

frank-iii avatar

Watchers

 avatar

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.