GithubHelp home page GithubHelp logo

typed-prompts's Introduction

Tylor Steinberger

I'm a self-taught engineer with a passion for learning, creating, and contributing. I'm an Open Source Enthusiast; Author of Motorcycle.ts, Typed; Contributor to Effect, Cycle, Most, and Snabbdom among maintaining and contributing to numerous other open-source libraries you'll find across my profile.

Software is my passion, and I want to build tools for the future.

TylorS' Github Status

My GitHub Streak

typed-prompts's People

Contributors

matiboy avatar tylors avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Forkers

matiboy

typed-prompts's Issues

"default" to be typed to Default<string> for InputQuestion

Code to reproduce the issue:

    prompt([input('age', 'Age'),
    input('participant_age', 'Participant age (minimum 18)', {
      default: answers => {
        let age = parseInt(answers.age);
        if(age >= 18) {
          return age.toString();
        }
        return '';
      })])

Expected behavior:
default can be a string or a function that returns a string. Typing to Default would allow correct behavior.

Actual behavior:
Currently this is rejected by the definition which is only

Versions of packages used:
"typed-prompts": "^1.0.0"

Thank you for coming up with the definitions for inquirer! Really useful

Error when creating separator

Code to reproduce the issue:

import { prompt, list, separator } from 'typed-prompts';

prompt([
  list('das','dsa',[
    'Hi!',
    separator()
  ])
]);

Expected behavior:
Creates a new separator. In index.ts, replacing createSeparator with return new Separator(); seems to work

Actual behavior:
Error: inquirer_1.separator is not a function

Versions of packages used:

  • typed-prompts=1.1.0
  • inquirer=1.2.3

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.