Skip to content

Commit

Permalink
Merge branch 'develop' into fix/debounce-like-post
Browse files Browse the repository at this point in the history
  • Loading branch information
NiallJoeMaher authored Oct 3, 2024
2 parents a824aca + 953918d commit ee9c6f9
Show file tree
Hide file tree
Showing 10 changed files with 21,475 additions and 22,502 deletions.
4 changes: 2 additions & 2 deletions components/ui/Search.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import {
type AutocompleteCollection,
} from "@algolia/autocomplete-core";
import { getAlgoliaResults } from "@algolia/autocomplete-preset-algolia";
import algoliasearch from "algoliasearch/lite";
import { liteClient as algoliasearch } from "algoliasearch/lite";
import {
Dialog,
DialogPanel,
Expand Down Expand Up @@ -113,8 +113,8 @@ function useAutocomplete({
queries: [
{
indexName: ALGOLIA_SOURCE_IDX,
query,
params: {
query,
hitsPerPage: 6,
},
},
Expand Down
26 changes: 26 additions & 0 deletions instrumentation.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
import * as Sentry from "@sentry/nextjs";

const SENTRY_DSN = process.env.SENTRY_DSN || process.env.NEXT_PUBLIC_SENTRY_DSN;
const SENTRY_ENVIRONMENT = process.env.SENTRY_ENVIRONMENT;

export function register() {
if (process.env.NEXT_RUNTIME === "nodejs") {
// this is your Sentry.init call from `sentry.server.config.js|ts`
Sentry.init({
dsn: SENTRY_DSN,
// Adjust this value in production, or use tracesSampler for greater control
tracesSampleRate: 1,
environment: SENTRY_ENVIRONMENT,
});
}

// This is your Sentry.init call from `sentry.edge.config.js|ts`
if (process.env.NEXT_RUNTIME === "edge") {
Sentry.init({
dsn: SENTRY_DSN,
// Adjust this value in production, or use tracesSampler for greater control
tracesSampleRate: 1,
environment: SENTRY_ENVIRONMENT,
});
}
}
2 changes: 1 addition & 1 deletion next-env.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
/// <reference types="next/image-types/global" />

// NOTE: This file should not be edited
// see https://nextjs.org/docs/basic-features/typescript for more information.
// see https://nextjs.org/docs/app/building-your-application/configuring/typescript for more information.
20 changes: 9 additions & 11 deletions next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,20 +39,18 @@ const config = {
// Temporary to check pipelines due to weird error I can only get on CodePipeline
ignoreBuildErrors: true,
},
experimental: {
instrumentationHook: true,
},
};

// Injected content via Sentry wizard below

const { withSentryConfig } = require("@sentry/nextjs");

module.exports = withSentryConfig(
withMDX(withBundleAnalyzer(config)),
{
silent: true,
org: "codu",
project: "codu",
},
{
hideSourceMaps: true,
},
);
module.exports = withSentryConfig(withMDX(withBundleAnalyzer(config)), {
silent: true,
org: "codu",
project: "codu",
hideSourceMaps: true,
});
Loading

0 comments on commit ee9c6f9

Please sign in to comment.