Security News
Create React App Officially Deprecated Amid React 19 Compatibility Issues
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
github.com/cbrgm/dialog
Go module to parse input data and return it as a Go basic type
package main
import (
"fmt"
"github.com/cbrgm/dialog"
"os"
)
func main() {
// Ask for username from stdin, default "foo bar", don't skip
fmt.Println("Please enter your name:")
name, err := dialog.AskForString(os.Stdin, "foo bar", false)
if err != nil {
print(err)
}
// Ask for status from stdin, default "true", don't skip
// Blocks until the user enters eiter y (yes), n (no), or q (quit)
fmt.Println("Are you hungry? [y/n/q]:")
hungry, err := dialog.AskForBool(os.Stdin, true, false)
if err != nil {
print(err)
}
// Ask for going out from stdin, block until user enters 'yes' or 'no', max 3 attempts, don't skip
// If user hits Strg+C, false is returned
fmt.Println("Pizza!? [y/n]:")
pizza := dialog.AskForConfirmation(os.Stdin, 3, false)
if err != nil {
print(err)
}
fmt.Printf("%s, is hungry (%t), wants to eat pizza (%t)!", name, hungry, pizza)
}
$ go get github.com/cbrgm/dialog
dialog
is open-source and is developed under the terms of the MIT.
Maintainer of this repository is:
Please refer to the git commit log for a complete list of contributors.
See the Contributing Guide.
FAQs
Unknown package
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.