Skip to content

[UI] - Add UX indicator routing key is being injected in the page #49

@davixcky

Description

@davixcky
Image

The idea is to show a banner that indicates some headers are being injected in all requests. However to not look intrusive we will add an option under settings to allow setting up the urls user want to inject

const minimatch = require("minimatch");

// Example patterns and URLs
const patterns = [
  "*",  // Matches any URL
  ".*://localhost:3000/.*",  // Matches URLs starting with http://localhost:3000 or https://localhost:3000
  "*signadot.com*",  // Matches any URL that contains "signadot.com"
];

const urls = [
  "http://localhost:3000/somepath",
  "https://localhost:3000/anotherpath",
  "https://signadot.com",
  "https://example.com",
];

// Function to check if any URL matches any of the patterns
const matchUrls = (patterns, urls) => {
  return urls.filter(url => patterns.some(pattern => minimatch(url, pattern)));
};

cc: @foxish

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions