GithubHelp home page GithubHelp logo

Cats are big about cat-pad HOT 7 OPEN

callumacrae avatar callumacrae commented on May 21, 2024
Cats are big

from cat-pad.

Comments (7)

sindresorhus avatar sindresorhus commented on May 21, 2024 22

I'd suggest padding the string with half a cat, instead.

Are you sure you want that? 😜

half-cat

from cat-pad.

sindresorhus avatar sindresorhus commented on May 21, 2024 2
const cats = new String('🐈🐈Meow');
Object.defineProperty(cats, 'meowlength', {value: 6});

cats.meowlength === 6;
//=> true

from cat-pad.

mk-pmb avatar mk-pmb commented on May 21, 2024 1

This is preventing me from using this in production. Is there a fix yet?

My apologies for the continuing lack of progress with this severe malfunction.
I summoned my emergency advisors panel today, and the expert cats seemed to almost have reached a consensus for using U+264C leo (β™Œ) as a first stage workaround. Unfortunately, they then discovered U+2653 pisces (β™“) and adjourned the meeting to visit the nearby creek.

from cat-pad.

mk-pmb avatar mk-pmb commented on May 21, 2024

Well, the Readme states

Padding cats are truncated if they exceed length.

which contradicts the example:

catPad('Meow', 6);
//=> '🐈🐈Meow'

because

'🐈🐈Meow'.length === 8

I'd say let's use UCS-2 characters for the length, and in the odd case, prefer the front half of the cat so it can still purr and make funny faces.

from cat-pad.

sindresorhus avatar sindresorhus commented on May 21, 2024

What if we used half an avocado when it's half? β†’ πŸ₯‘

from cat-pad.

mk-pmb avatar mk-pmb commented on May 21, 2024

My Unicode catalog's avocado uses 2 UCS-2 characters so that won't help. :-(

from cat-pad.

unitof avatar unitof commented on May 21, 2024

This is preventing me from using this in production. Is there a fix yet?

from cat-pad.

Related Issues (1)

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.