Skip to content
This repository has been archived by the owner on Apr 14, 2023. It is now read-only.

Improve link API and context #81

Merged
merged 15 commits into from
Sep 30, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -53,3 +53,6 @@ package-lock.json
# Compiled
dist
lib


.idea
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "docs/themes/meteor"]
path = docs/themes/meteor
url = https://github.com/meteor/hexo-theme-meteor.git
10 changes: 5 additions & 5 deletions dangerfile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const filesOnly = (file: string) =>

// Custom subsets of known files
const modifiedAppFiles = modified
.filter(p => includes(p, 'src/') || includes(p, 'test/'))
.filter(p => includes(p, 'src') || includes(p, '__tests__'))
.filter(p => filesOnly(p) && typescriptOnly(p));

// Takes a list of file paths, and converts it into clickable links
Expand Down Expand Up @@ -71,10 +71,10 @@ if (!isBot) {

// When there are app-changes and it's not a PR marked as trivial, expect
// there to be CHANGELOG changes.
const changelogChanges = modified.some(x => x.indexOf('CHANGELOG') > -1);
if (modifiedAppFiles.length > 0 && !trivialPR && !changelogChanges) {
fail('No CHANGELOG added.');
}
// const changelogChanges = modified.some(x => x.indexOf('CHANGELOG') > -1);
// if (modifiedAppFiles.length > 0 && !trivialPR && !changelogChanges) {
// fail('No CHANGELOG added.');
// }

// No PR is too small to warrant a paragraph or two of summary
if (pr.body.length === 0) {
Expand Down
8 changes: 8 additions & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
.DS_Store
Thumbs.db
db.json
*.log
node_modules/
public/
.deploy*/
docs.json
3 changes: 3 additions & 0 deletions docs/.gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "themes/meteor"]
path = themes/meteor
url = https://github.com/meteor/hexo-theme-meteor.git
12 changes: 12 additions & 0 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# docs

[![Greenkeeper badge](https://badges.greenkeeper.io/apollographql/react-docs.svg)](https://greenkeeper.io/)

To run:

```
git clone --recursive https://github.com/apollographql/react-docs.git
cd react-docs
npm install
npm start
```
101 changes: 101 additions & 0 deletions docs/_config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
# Hexo Configuration
## Docs: http://hexo.io/docs/configuration.html
## Source: https://github.com/hexojs/hexo/

# Site
title: Apollo Link Docs
propertytitle: Using Apollo Link
subtitle: Apollo Link Guide
description: A guide to using Apollo Link to customize Apollo Client.
author:
language:
timezone:
versions:
- '1'
sidebar_categories:
null:
- index
- installation
- concepts
Usage:
- stateless
- stateful
- composition
Copy link
Contributor

Choose a reason for hiding this comment

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

I think we could really use a Recipes section here, with stuff like:

  • Setting headers
  • Error handling
  • Subscriptions

And maybe a Links section with all of the individual Link READMEs.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I agree! I haven't gotten around to doing that yet but we should totally have one! cc @peggyrayzis

github_repo: apollographql/apollo-link
content_root: source

typescript_api_box:
data_file: docs.json

social_links:
github: 'https://github.com/apollographql'
twitter: '@apollographql'
slackInvitePage: 'https://www.apollodata.com/#slack'

# API keys
apis:
segment: wgrIo8Bul0Ujl8USETG3DB6hONdy4kTg
docsearch:
apiKey: 768e823959d35bbd51e4b2439be13fb7
indexName: apollodata
gtm: GTM-PNFDVBB

# URL
## If your site is put in a subdirectory, set url as 'http://yoursite.com/child' and root as '/child/'
url: http://dev.apollodata.com/links
root: /links/
permalink: :year/:month/:day/:title/
permalink_defaults:

# Directory
source_dir: source
public_dir: public
tag_dir: tags
archive_dir: archives
category_dir: categories
code_dir: downloads/code
i18n_dir: :lang
skip_render:

# Writing
new_post_name: :title.md # File name of new posts
default_layout: post
titlecase: false # Transform title into titlecase
external_link: true # Open external links in new tab
filename_case: 0
render_drafts: false
post_asset_folder: false
relative_link: false
future: true
highlight:
enable: true
line_number: true
auto_detect: true
tab_replace:

# Category & Tag
default_category: uncategorized
category_map:
tag_map:

# Date / Time format
## Hexo uses Moment.js to parse and display date
## You can customize the date format as defined in
## http://momentjs.com/docs/#/displaying/format/
date_format: YYYY-MM-DD
time_format: HH:mm:ss

# Pagination
## Set per_page to 0 to disable pagination
per_page: 10
pagination_dir: page

# Extensions
## Plugins: http://hexo.io/plugins/
## Themes: http://hexo.io/themes/
theme: meteor

# Deployment
## Docs: http://hexo.io/docs/deployment.html
deploy:
type:
1 change: 1 addition & 0 deletions docs/assets/theme-colors.less
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@color-primary: #22A699;
26 changes: 26 additions & 0 deletions docs/circle.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
machine:
node:
version: 8.1.2

checkout:
post:
- git submodule update --init

dependencies:
cache_directories:
- "site/node_modules"
override:
- npm install -g hexo-cli
- npm install
- cd code; npm install

test:
override:
# maybe we will need tests in the future
- echo 'ok!'

deployment:
s3:
branch: /^(master|version-.*)/
commands:
- npm run deploy
Loading