How to use the insomnia-cookies.cookieToString function in insomnia-cookies

To help you get started, we’ve selected a few insomnia-cookies examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Kong / insomnia / packages / insomnia-app / app / ui / components / modals / cookie-modify-modal.js View on Github external
_getRawCookieString() {
    const { cookie } = this.state;

    if (!cookie) {
      return '';
    }

    try {
      return cookieToString(toughCookie.Cookie.fromJSON(JSON.stringify(cookie)));
    } catch (err) {
      console.warn('Failed to parse cookie string', err);
      return '';
    }
  }
github Kong / insomnia / packages / insomnia-app / app / ui / components / cookie-list.js View on Github external
{cookies.map((cookie, i) => {
              const cookieString = cookieToString(toughCookie.Cookie.fromJSON(cookie));
              return (
                <tr className="selectable" key={i}>
                  <td>
                    <RenderedText render={handleRender}>{cookie.domain || ''}</RenderedText>
                  </td>
                  <td className="force-wrap wide">
                    <RenderedText render={handleRender}>{cookieString || ''}</RenderedText>
                  </td>
                  <td onClick={null} className="text-right no-wrap">
                    <button
                      className="btn btn--super-compact btn--outlined"
                      onClick={e => handleShowModifyCookieModal(cookie)}
                      title="Edit cookie properties">
                      Edit
                    </button>{' '}
                    <PromptButton

insomnia-cookies

Cookie utilities

MIT
Latest version published 2 months ago

Package Health Score

62 / 100
Full package analysis

Similar packages