Code Monkey home page Code Monkey logo

web-utility's People

Contributors

rabbitom avatar shakalakab avatar soecka avatar techquery avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

rabbitom soecka

web-utility's Issues

bug: no value when use single radio or checkbox in form

In formToJSON, when there's only one radio or checkbox for a name(acting as a switch), and if that radio/checkbox is not checked, there would be no such field in the return json object.
So if user turn off a switch when updating a form, it would not work, the field would still be on.

[enhancement]: scrollIntoViewOptions

MDN_scrollIntoView
API-Docs_scrollTo

  • behavior Optional
    Defines the transition animation. One of auto or smooth. Defaults to auto.

  • block Optional
    Defines vertical alignment. One of start, center, end, or nearest. Defaults to start.

  • inline Optional
    Defines horizontal alignment. One of start, center, end, or nearest. Defaults to nearest.

enhancement: toHyphenCase() convert space to camelCase

In toHyphenCase, I cann't convert to 'socia media' to 'socia-media'
data.ts:32
maybe we can polish the pattern of the regExp

function toHyphenCase(raw:string) {
  return raw.replace(
      /[A-Z]+|[^A-Za-z][A-Za-z]/g,
      (match, offset) => `${offset ? '-' : ''}${(match[1]||match[0]).toLowerCase()}`
  );
}

Upgrade TypeScript version

When I use https://github.com/idea2app/REST-Node-ts npm install error message:

npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR! 
npm ERR! While resolving: @idea2app/[email protected]
npm ERR! Found: [email protected]
npm ERR! node_modules/typescript
npm ERR!   dev typescript@"~5.1.6" from the root project
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer typescript@"^4.1.0" from [email protected]
npm ERR! node_modules/web-utility
npm ERR!   web-utility@"^4.0.0" from the root project
npm ERR! 
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution

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.