Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial nodejs string wrap #151

Open
wants to merge 1 commit into
base: main-dev
Choose a base branch
from

Conversation

MarkReedZ
Copy link
Contributor

I've created a Str object wrapper for Node.js

    const a = new stringzilla.Str('hello world');
    const b = new stringzilla.Str('hi');

    const result_1 = a.count(b);

And implemented a few functions with tests.

        {"indexOf", NULL, str_find, NULL, NULL, NULL, napi_default, NULL},
        {"find", NULL, str_find, NULL, NULL, NULL, napi_default, NULL},
        {"rfind", NULL, str_rfind, NULL, NULL, NULL, napi_default, NULL},
        {"startswith", NULL, str_startswith, NULL, NULL, NULL, napi_default, NULL},
        {"endswith", NULL, str_endswith, NULL, NULL, NULL, napi_default, NULL},
        {"count", NULL, str_count, NULL, NULL, NULL, napi_default, NULL}

@ashvardanian ashvardanian force-pushed the main-dev branch 2 times, most recently from 430f05e to f7e4c05 Compare August 5, 2024 21:01
@ashvardanian ashvardanian force-pushed the main-dev branch 4 times, most recently from 19e6998 to 4e33434 Compare October 17, 2024 06:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant