diff --git a/www/_blog/2020-08-05-supabase-auth.mdx b/www/_blog/2020-08-05-supabase-auth.mdx
index 0a0b8f5abd0..71644d4c3e0 100644
--- a/www/_blog/2020-08-05-supabase-auth.mdx
+++ b/www/_blog/2020-08-05-supabase-auth.mdx
@@ -60,21 +60,18 @@ Authentication only gets you so far. When you need granular authorization rules,
With policies, your database becomes the rules engine. Instead of repetitively filtering your queries, like this ...
-
+```
... you can simply define a rule on your database table, `auth.uid() = user_id`, and your request will return the rows which pass the rule, even when you remove the filter from your middleware:
-
+```js
+let user = await supabase.from('users').select('user_id, name')\n
+// Still returns { id: 'd0714948', name: 'Jane' }
+```
### Open source
diff --git a/www/_blog/2020-10-30-improved-dx.mdx b/www/_blog/2020-10-30-improved-dx.mdx
index 114251c6e96..c58786cf7ca 100644
--- a/www/_blog/2020-10-30-improved-dx.mdx
+++ b/www/_blog/2020-10-30-improved-dx.mdx
@@ -30,24 +30,21 @@ We attribute this improvement to community feedback. This has significantly impr
Previously we would throw errors:
-
+}
+```
And now we simply return them:
-
+// else, carry on ..
+```
After testing this for a while we're very happy with this pattern. Errors are handled next to the offending function. Of course you can always rethrow the error if that's your preference.
@@ -59,23 +56,20 @@ To maintain this philosophy, we created [`gotrue-js`](https://github.com/supabas
Previously:
-
+} = await supabase.auth.signup('someone@email.com', 'password')
+```
Now:
-
+})
+```
### Enhancements and fixes
@@ -97,11 +91,15 @@ We've bumped the major version because there are a number of breaking changes. W
Previously:
-
+```js
+const { body } = supabase.from('todos').select('*')
+```
Now:
-
+```js
+const { data } = supabase.from('todos').select()
+```
### Upgrading
diff --git a/www/_blog/2020-12-13-supabase-dashboard-performance.mdx b/www/_blog/2020-12-13-supabase-dashboard-performance.mdx
index 40defdf17d9..2cd55b2b6fc 100644
--- a/www/_blog/2020-12-13-supabase-dashboard-performance.mdx
+++ b/www/_blog/2020-12-13-supabase-dashboard-performance.mdx
@@ -53,17 +53,15 @@ We reverted our [crypto-js](https://github.com/brix/crypto-js) module from versi
By selectively importing functions from modules like `lodash`, we cut the gzipped size by another 40kb across all our bundles.
-
+```
In the above example, we added [babel-plugin-lodash](https://github.com/lodash/babel-plugin-lodash) to our babel configuration which cherry picks the exact `lodash` functions we import. This makes it easier to import from `lodash` without cluttering the code with selective import statements.
diff --git a/www/_blog/2021-01-02-supabase-beta-december-2020.mdx b/www/_blog/2021-01-02-supabase-beta-december-2020.mdx
index f32cec50fbc..df53233bda6 100644
--- a/www/_blog/2021-01-02-supabase-beta-december-2020.mdx
+++ b/www/_blog/2021-01-02-supabase-beta-december-2020.mdx
@@ -14,8 +14,6 @@ date: '01-02-2020'
After 10 hectic months of building, Supabase is now in Beta.
-
-
### Quick demo
Watch a full demo:
diff --git a/www/pages/blog/[slug].tsx b/www/pages/blog/[slug].tsx
index 444a93f275b..03e14707dd5 100644
--- a/www/pages/blog/[slug].tsx
+++ b/www/pages/blog/[slug].tsx
@@ -71,10 +71,18 @@ export async function getStaticProps({ params }: any) {
})
.indexOf(params.slug)
+ console.log('currentIndex', currentIndex)
+ console.log('allPosts.length', allPosts.length)
+
+ console.log('nextPost', allPosts[currentIndex + 1])
+
+ const nextPost = allPosts[currentIndex + 1]
+ const prevPost = allPosts[currentIndex - 1]
+
return {
props: {
- prevPost: currentIndex === 0 ? null : allPosts[currentIndex - 1],
- nextPost: currentIndex === allPosts.length ? null : allPosts[currentIndex + 1],
+ prevPost: currentIndex === 0 ? null : prevPost ? prevPost : null,
+ nextPost: currentIndex === allPosts.length ? null : nextPost ? nextPost : null,
relatedPosts,
blog: {
slug: params.slug,
@@ -269,9 +277,9 @@ function BlogPostPage(props: any) {
{props.prevPost && }
- {props.nextPost && (
+ {/* {props.nextPost && (
- )}
+ )} */}