question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Improvements to documentation

See original GitHub issue

Here are some thoughts on things we need to cover in the docs

If you have more ideas, please comment below/edit this post if you have access.

Issue Analytics

  • State:open
  • Created 6 years ago
  • Reactions:3
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

3reactions
GeeWeecommented, May 9, 2017

I’d be willing to create a PR with a typescript recipe if there’s interest.

2reactions
miguelollercommented, Jun 8, 2017

Hey @satya164, just wanted to chime in and say that it’s also possible to avoid long relative requires by using Webpack. Here’s a Haul config I’ve been using that allows .jsx in React Native and allows to require anything inside src (e.g., require('components/MyButton')).

const path = require('path')

module.exports = ({ platform }, defaults) => ({
  entry: `./index.${platform}.js`,
  module: {
    ...defaults.module,
    rules: [
      ...defaults.module.rules,
      // Support .jsx
      {
        test: /\.jsx$/,
        use: {
          loader: require.resolve('happypack/loader'),
          query: { id: 'babel' },
        },
        include: path.resolve(__dirname, 'src'),
      },
    ],
  },
  resolve: {
    ...defaults.resolve,
    // Support .jsx
    extensions: [...defaults.resolve.extensions, '.jsx'],
    // Avoid extremely long relative imports
    modules: [path.resolve(__dirname, 'src'), 'node_modules'],
  },
})

More fine-grained control like babel-plugin-module-resolver can also be achieved using the resolve.alias option in Webpack but just using resolve.modules worked for my use case.

I’m also planning on adding react-hot-loader to support HMR for functional stateless components in React Native (currently unsupported). I wouldn’t mind contributing to the docs adding a couple of recipes.

Read more comments on GitHub >

github_iconTop Results From Across the Web

4 Steps for Documentation Improvement - Production Machining
Quality documentation can be improved. Whether you use a simple word processing program such as Word to document your processes, or a more ......
Read more >
How do I document improvement? - LinkedIn
Use a survey to define VOC (voice of customer) ; Use a PPM (parts per million defective) quality report to identify process issues...
Read more >
3 Tips to Improve Documentation Productivity - Nuance Blog
1. Make accuracy the cornerstone of documentation process improvement · 2. Factor mobility into your documentation workflow · 3. Acknowledge ...
Read more >
Five ways to improve clinical documentation and bridge the ...
Show how improving documentation in these areas would benefit the patient, practice, or population. Educate providers before establishing a program. Clinicians ...
Read more >
A Quality Improvement Project to Improve Documentation and ...
Nursing paper documentation of limitations of life-sustaining therapies increased sequentially from 0% to 88% during plan-do-study-act cycles.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found