Coder Social home page Coder Social logo

livewire-validator's Introduction

livewire-validator

Experimental podcast feed validator, supporting all of the new podcast namespace tags

Public version available at: https://validator.livewire.io/

Development setup

  • Ensure vscode is installed
  • Ensure Deno is installed
  • Ensure the Deno vscode extension is installed (from vscode -> Extensions)
  • There are two vscode projects:
    • code validator-app to work on the client-side javascript app
    • code validator-worker to work on the cli, server (Cloudflare Worker), or common validation logic
  • Run the standard deno test to run unit tests
  • Install the validator cli tool
    • (from the validator-worker dir) deno install --name validator -Af --unstable cli.ts
  • Run validator build to rebuild/embed the client app on any changes
  • Run validator validate <url> to quickly test validation rules on the command-line
  • Use denoflare serve to run the server on your local machine
    • Ensure denoflare is installed
    • Run without config (from the validator-worker dir): denoflare serve validator_worker.ts --watch-include static
    • Or using a .denoflare config file (example below): denoflare serve validator-local --watch-include static
    • See the config below for the optional worker environment variable bindings to configure secrets

Example .denoflare config

{
  // This file supports comments and trailing commas!
  "$schema": "https://raw.githubusercontent.com/skymethod/denoflare/v0.5.6/common/config.schema.json",
  "scripts": {
    "validator-local": {
      "path": "/path/to/livewire-validator/validator-worker/validator_worker.ts",
      "bindings": {
        // optional: displayed in the UI as the app version
        "version": { "value": "local" },

        // optional: needed for search
        "piCredentials": { "value": "<api-key>:<api-secret>" },

        // optional: needed for twitter api calls
        "twitterCredentials": { "value": "bearer:<bearer-token>" },

        // optional: needed for mastodon login to reply
        "origin" : { "value": "http://localhost:8820" },
        "mastodonClientName": { "value": "livewire-validator (local dev)" },
        "mastodonClientUrl": { "value": "https://github.com/skymethod/livewire-validator" },
        "storageNamespace": { "doNamespace": "local:StorageDO:storage=webstorage:container=validator-local" },
      },
      // optional: to run on a specific local port (default 8080)
      "localPort": 8820,
    },
  }
}

livewire-validator's People

Contributors

johnspurlock-skymethod 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.