From 428c7482fe02c06c9c20d11f7ba7eed7ee608fb9 Mon Sep 17 00:00:00 2001
From: Ayu Adiati <45172775+adiati98@users.noreply.github.com>
Date: Thu, 31 Oct 2024 18:32:48 +0100
Subject: [PATCH] feat: Add November 2024 Challenge to the Website (#1286)
* feat: add november 2024 challenge
* chore: add completed challenge alert to october 2024
* chore: update challenge homepage
* fix: wording and grammar
* Prettified Code!
* fix: minor wording change
* abstract writing challenge data
---------
Co-authored-by: adiati98
+ This month, we're working together to blog 50,000 words! Based off the{' '}
+
+ NaNoWriMo (National Novel Writing Month) Challenge
+
+ , we'll be doing the tech and non-tech take on writing and working
+ together towards the goal while posting on our own blogs.
+ Get those blog posts up!
+ Once you've written and published your content,{' '}
+
+ add your entry to our VC NaNoWriMo entry form
+
+ !
+
+ Any tech-related or non-tech blog posts, articles, or novels published
+ in November! For tech-related posts, feel free to include code samples
+ in your word count totals (if it's a word and you wrote it, we'll count
+ it 😊).
+
+ While we love good documentation here at Virtual Coffee, README docs, or
+ anything else you would typically consider documentation, it doesn't
+ count for this challenge.
+
+ We all start somewhere. The more you practice, the better you'll get. We
+ have volunteers willing to proofread and give you feedback on your
+ writing. Just put a link to your draft in the{' '}
+
+ We've got you covered with extensive topic lists in{' '}
+
+ this discussion
+ {' '}
+ and{' '}
+
+ this discussion
+
+ .
+ And remember, we're always here to help ❤️
- Based off the NaNoWriMo (National Novel Writing Month) Challenge, this
- challenge is the tech take on writing and working together towards the
+ Based on the NaNoWriMo (National Novel Writing Month) Challenge, this
+ challenge is the tech and non-tech take on writing and working together towards the
goal while posting on our own blogs.
+ {/*
Learn more about this challenge in{' '}
this blog post
.
-
+ Monthly Challenge for November 2024: Let's write 50k
+ words together!
+
+
+
+ Current status:
+
+
+
+ {completedGoals.map((goal, i) => (
+
+
+
+ Current status: {totals.totalCount.toLocaleString()} out of{' '}
+ {currentGoal?.title} words
+
+ )}
+
+ Our Posts:
+
+ {sortedList.map((author, i) => (
+
+ {author.name}
+
+
+
+ Permalink to {author.name}'s posts
+
+
+
+
+ {author.posts.map((post, j) => (
+
+ ({post.count.toLocaleString()} words)
+ Totals:
+
+
+
+
+ >
+ )}
+
+
+
+
+
+ {totals.list.map((author, i) => (
+ Member Totals
+
+ Posts
+
+
+ Total Words
+
+
+
+ ))}
+
+
+ {author.name}
+
+ {author.posts.toLocaleString()}
+
+
+ {author.total.toLocaleString()}
+
+
+
+
+ Total
+
+ {totals.totalPosts.toLocaleString()}
+
+
+ {totals.totalCount.toLocaleString()} words
+
+ How to Participate
+
+ What kind of content counts towards the challenge?
+
+ What if I'm not confident about my writing?
+
+ #monthly-challenge
or #content-creation
{' '}
+ channel and ask for the help you need.
+ What if I don't know what to write about?
+
+ Resources
+
+
Monthly Challenge for October 2024: It's Hacktoberfest!
Participate in open source, learn, and have fun!
diff --git a/src/app/monthlychallenges/page.tsx b/src/app/monthlychallenges/page.tsx
index ceb3a62c..b1b2d1a1 100644
--- a/src/app/monthlychallenges/page.tsx
+++ b/src/app/monthlychallenges/page.tsx
@@ -190,26 +190,27 @@ const challengeList: Challenge[] = [
],
},
{
+ current: true,
title: 'Blogging Challenge',
- subtitle: `A Community Challenge to hit a word count goal for all our tech blogs.`,
+ subtitle: `A Community Challenge to hit a word count goal for all our tech and non-tech blogs.`,
description: (
<>
To view all of the details of this year's challenge,{' '} - - check out the November 2023 challenge page + + check out the November 2024 challenge page .
@@ -217,6 +218,9 @@ const challengeList: Challenge[] = [ ), links: [ { + href: '/monthlychallenges/nov-2023', + title: 'November, 2023', + }, { href: '/monthlychallenges/nov-2022', title: 'November, 2022', }, @@ -231,7 +235,6 @@ const challengeList: Challenge[] = [ ], }, { - current: true, title: 'Hacktoberfest', subtitle: `Participate in open source, learn, and have fun!`, description: ( diff --git a/src/data/monthlyChallenges/nov-2023.ts b/src/data/monthlyChallenges/NaNoWriMo.ts similarity index 96% rename from src/data/monthlyChallenges/nov-2023.ts rename to src/data/monthlyChallenges/NaNoWriMo.ts index 9fde5130..419837dc 100644 --- a/src/data/monthlyChallenges/nov-2023.ts +++ b/src/data/monthlyChallenges/NaNoWriMo.ts @@ -12,7 +12,7 @@ type NovRow = { created_at: string; }; -async function fetchRecords() { +async function fetchRecords(viewName: string) { if (process.env.PUBLIC_AIRTABLE_API_KEY) { const base = new Airtable({ apiKey: process.env.PUBLIC_AIRTABLE_API_KEY, @@ -20,7 +20,7 @@ async function fetchRecords() { const result = await base