Comments (3)
Update!
I've merged in @broccolini 's changes in #72 and using the _app.js file + importing the Index component from docs.js seems to have fixed all our issues regarding reloading! π π π
Going to work on getting permalinks working next!
from react.
Update on this for the team! @primer/ds-core
TLDR; I've got HMR mostly running, the fix was to rename the index.js file in /examples to something besides index, but that creates another issue with the base page that loads up when x0 is started being an unstyled page just showing all the files in /examples. Permalinks still aren't working
Update
I got HMR working again by renaming the index in the examples folder to something else, then changing x0 config's basename to '/', but I'm running into a few issues!
-
When running
x0 dev examples -op 8888
, I get taken to an unstyled index page listing all the files in my examples folder, since I don't have an index in that folder anymore. If I try runningx0 dev examples/docs.js -op 8888
instead, the first load brings me to the examples/docs.js like I'd like it to, but when HMR kicks in after a change, it brings me back to the unstyled page listing the files in examples/docs.js. The URL in the browser is correct though (ex. [http://localhost:8888/docs/primer-react/Box] [name of index file/name of library/name of example]). -
I did set up a in my examples/docs.js file (previously examples/index.js) and I'm curious if that might be causing the issue here? Jackson mentioned that x0 already has routing set up, but it looks like that's just for routing in between Example components in a Library, I'm assuming that wouldn't work out of the box for just simple routing between components from the index page (ex. I have a Demos Library, Components Library, and Sandbox I'd like to add to the top navigation)
-
I also had to set the
basename
config for x0 to/
in order to get the docs to build, not sure if that is having something to do with it? -
When we publish our static builds to GitHub Pages, navigation works around Kit, but if I copy the link and paste it in a different tab, I get a 404. Honestly not sure if this is a x0 issue or a GitHub Pages issue
from react.
Done in #77.
from react.
Related Issues (20)
- Dialog: Support a responsive value for `isOpen` HOT 2
- Confusion between Dialog and DialogV1 HOT 1
- Proposal: Keybinding hints in tooltips / icon buttons HOT 5
- [Bug] `ActionMenu` still scrolls if in `sticky` container HOT 4
- ButtonGroup styling is not compatible with new IconButton tooltips HOT 2
- Release Tracking
- `FormControl` component is missing `className` prop
- RelativeTime component appears broken HOT 6
- Release Tracking
- Need access to `FilteredActionList` to create a stopgap modal `SelectPanel`
- TextInput: Value/Placeholder font size doesn't respect it's size variant HOT 2
- IconButton: color override not applied for medium size HOT 2
- Release Tracking
- Release Tracking
- `ActionList.Leading/TrailingVisual` is invisible to screen readers HOT 2
- `TextInput` `leading/trailingVisual` is not semantically associated with the input HOT 1
- Add `type` to all internal `button` elements HOT 3
- UnderlineNav doesn't update its tabs when the items change HOT 8
- Release Tracking
- ActionMenu with overflow doesnβt contain scrollbars within its rounded border HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react.