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

Fuzzy search for properties #4091

Merged
merged 1 commit into from
Apr 23, 2021
Merged

Fuzzy search for properties #4091

merged 1 commit into from
Apr 23, 2021

Conversation

timgl
Copy link
Collaborator

@timgl timgl commented Apr 23, 2021

Changes

Add fuzzy search to the properties dropdown for ease of use. A specific thing I ran against was typing utm campaign which didn't work as the actual key is $utm_campaign. Tested up to 10k props and it's fast.

Checklist

  • All querysets/queries filter by Organization, by Team, and by User
  • Django backend tests
  • Jest frontend tests
  • Cypress end-to-end tests
  • Migrations are safe to run at scale (e.g. PostHog Cloud) – present proof if not obvious

@timgl timgl requested a review from samwinslow April 23, 2021 12:33
@@ -1,4 +1,5 @@
import React from 'react'
import React, { useState } from 'react'
import Fuse from 'fuse.js'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've used Fuse before, it's pretty great.

@timgl timgl temporarily deployed to posthog-pr-4091 April 23, 2021 12:38 Inactive
Copy link
Contributor

@samwinslow samwinslow left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great experience improvement. +1 to what @buwilliams said — Fuse is quite powerful.

@samwinslow samwinslow merged commit e144111 into master Apr 23, 2021
@samwinslow samwinslow deleted the fuzzy-search-properties branch April 23, 2021 17:36
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.

None yet

3 participants