Repository docs

Lukang689

Lukang689 posted a new question

docs • 13 hours ago

How import .scss only?

I defined some scss variable in a scss file. I don't want to compile them.
By scss document, a scss file's name with the begining of "_", when the file imported, it will not be compiled.But,in nuxt.js, this method will occurr error.
What I should do?

qq510846

qq510846 posted a new question

docs • 2 days ago

how to use [hash] in publicPath on nuxt.config.js

I use "qiniu-webpack-plugin", and i want use [hash] to publicPath, how can i do?

If i use like:
publicPath: 'http://pflm0b2yz.bkt.clouddn.com/[hash]/'

and, i will get errors:
ERROR in chunk runtime [entry]
[chunkhash].js
Cannot use [chunkhash] or [contenthash] for chunk in '[chunkhash].js' (use [hash] instead)

manniL

manniL posted a new feature request

docs • 5 days ago

idea Document async nuxt.config.js

What problem does this feature solve?

https://github.com/nuxt/nuxt.js/pull/4021

manniL

manniL posted a new bug report

docs • 5 days ago

bug Fix source links

After the monorepo refactor source links are off. We should point them again to the right spots. Example: internals

XiaoBelly

XiaoBelly posted a new question

docs • 5 days ago

FATAL ERROR: CALL_AND_RETRY_LAST

FATAL ERROR: CALLANDRETRY_LAST Allocation failed - JavaScript heap out of memory

<--- Last few GCs --->

[88965:0x102800600] 56404 ms: Mark-sweep 1266.8 (1553.2) -> 1266.2 (1508.2) MB, 364.3 / 0.0 ms allocation failure GC in old space requested
[88965:0x102800600] 56657 ms: Mark-sweep 1266.2 (1508.2) -> 1266.2 (1455.2) MB, 251.7 / 0.0 ms last resort GC in old space requested
[88965:0x102800600] 56908 ms: Mark-sweep 1266.2 (1455.2) -> 1266.2 (1441.7) MB, 250.8 / 0.0 ms last resort GC in old space requested

<--- JS stacktrace --->

==== JS stack trace =========================================

Security context: 0x996fca5879 <JSObject>
1: fromString(aka fromString) [buffer.js:314] [bytecode=0x997ab75af9 offset=164](this=0x9924a822d1 <undefined>,string=0x997c8abce1 <Very long string[93620486]>,encoding=0x996fcb58e9 <String[4]: utf8>)
2: from [buffer.js:177] [bytecode=0x997ab75601 offset=11](this=0x99eae364f1 <JSFunction Buffer (sfi = 0x996fcfc461)>,value=0x997c8abce1 <Very long string[93620486]>,encodingOrOffset=0x996fcb5…

FATAL ERROR: CALLANDRETRYLAST Allocation failed - JavaScript heap out of memory 1: node::Abort() [/usr/local/bin/node] 2: node::FatalException(v8::Isolate, v8::Local<v8::Value>, v8::Local<v8::Message>) [/usr/local/bin/node] 3: v8::internal::V8::FatalProcessOutOfMemory(char const, bool) [/usr/local/bin/node]
4: v8::internal::Factory::NewRawTwoByteString(int, v8::internal::PretenureFlag) [/usr/local/bin/node]
5: v8::internal::String::SlowFlatten(v8::internal::Handle<v8::internal::ConsString>, v8::internal::PretenureFlag) [/usr/local/bin/node]
6: v8::String::WriteUtf8(char, int, int, int) const [/usr/local/bin/node]
7: node::StringBytes::Write(v8::Isolate, char, unsigned long, v8::Local<v8::Value>, node::encoding, int) [/usr/local/bin/node] 8: node::Buffer::New(v8::Isolate, v8::Local<v8::String>, node::encoding) [/usr/local/bin/node]
9: node::Buffer::(anonymous namespace)::CreateFromString(v8::FunctionCallbackInfo<v8::Value> const&) [/usr/local/bin/node]
10: v8::internal::FunctionCallbackArguments::Call(void ()(v8::FunctionCallbackInfo<v8::Value> const&)) [/usr/local/bin/node] 11: v8::internal::MaybeHandle<v8::internal::Object> v8::internal::(anonymous namespace)::HandleApiCallHelper<false>(v8::internal::Isolate, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::internal::Handle<v8::internal::Object>, v8::internal::BuiltinArguments) [/usr/local/bin/node]
12: v8::internal::Builtin
Impl_HandleApiCall(v8::internal::BuiltinArguments, v8::internal::Isolate*) [/usr/local/bin/node]
13: 0x234a81042fd
Abort trap: 6

XiaoBelly

XiaoBelly posted a new question

docs • 5 days ago

FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory

<--- Last few GCs --->
[88965:0x102800600] 56404 ms: Mark-sweep 1266.8 (1553.2) -> 1266.2 (1508.2) MB, 364.3 / 0.0 ms allocation failure GC in old space requested
[88965:0x102800600] 56657 ms: Mark-sweep 1266.2 (1508.2) -> 1266.2 (1455.2) MB, 251.7 / 0.0 ms last resort GC in old space requested
[88965:0x102800600] 56908 ms: Mark-sweep 1266.2 (1455.2) -> 1266.2 (1441.7) MB, 250.8 / 0.0 ms last resort GC in old space requested
<--- JS stacktrace --->
==== JS stack trace =========================================
Security context: 0x996fca5879 <JSObject>
1: fromString(aka fromString) [buffer.js:314] [bytecode=0x997ab75af9 offset=164](this=0x9924a822d1 <undefined>,string=0x997c8abce1 <Very long string[93620486]>,encoding=0x996fcb58e9 <String[4]: utf8>)
2: from [buffer.js:177] [bytecode=0x997ab75601 offset=11](this=0x99eae364f1 <JSFunction Buffer (sfi = 0x996fcfc461)>,value=0x997c8abce1 <Very long string[93620486]>,encodingOrOffset=0x996fcb5…
FATAL ERROR: CALLANDRETRYLAST Allocation failed - JavaScript heap out of memory 1: node::Abort() [/usr/local/bin/node] 2: node::FatalException(v8::Isolate, v8::Local<v8::Value>, v8::Local<v8::Message>) [/usr/local/bin/node] 3: v8::internal::V8::FatalProcessOutOfMemory(char const, bool) [/usr/local/bin/node]
4: v8::internal::Factory::NewRawTwoByteString(int, v8::internal::PretenureFlag) [/usr/local/bin/node]
5: v8::internal::String::SlowFlatten(v8::internal::Handle<v8::internal::ConsString>, v8::internal::PretenureFlag) [/usr/local/bin/node]
6: v8::String::WriteUtf8(char, int, int, int) const [/usr/local/bin/node]
7: node::StringBytes::Write(v8::Isolate, char, unsigned long, v8::Local<v8::Value>, node::encoding, int) [/usr/local/bin/node] 8: node::Buffer::New(v8::Isolate, v8::Local<v8::String>, node::encoding) [/usr/local/bin/node]
9: node::Buffer::(anonymous namespace)::CreateFromString(v8::FunctionCallbackInfo<v8::Value> const&) [/usr/local/bin/node]
10: v8::internal::FunctionCallbackArguments::Call(void ()(v8::FunctionCallbackInfo<v8::Value> const&)) [/usr/local/bin/node] 11: v8::internal::MaybeHandle<v8::internal::Object> v8::internal::(anonymous namespace)::HandleApiCallHelper<false>(v8::internal::Isolate, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::internal::Handle<v8::internal::Object>, v8::internal::BuiltinArguments) [/usr/local/bin/node]
12: v8::internal::Builtin
Impl_HandleApiCall(v8::internal::BuiltinArguments, v8::internal::Isolate*) [/usr/local/bin/node]
13: 0x234a81042fd
Abort trap: 6

antony

antony posted a new question

docs • 6 days ago

Where are older docs?

I've just visited the Nuxt site to find that the docs are now for version 2.x - last time i checked they were 1.x!

We've not quite moved to v2.x yet, so how can I get docs for my existing application?

manniL

manniL posted a new feature request

docs • 7 days ago

idea Custom directory names

What problem does this feature solve?

https://github.com/nuxt/nuxt.js/pull/2748 is not documented!

purdx

purdx posted a new question

docs • 8 days ago

babel js configuration

How should I add a new plugin or presets to the babel?
I've seen the docs but it doesn't explain the process?

Thanks in advance.

purdx

purdx posted a new question

docs • 9 days ago

Prababely a mistake in docs

In Vuex Store page, in "The nuxtServerInit Action" section, it says:
"The context is given to nuxtServerInit as the 2nd argument, it is the same as asyncData or fetch method."

But in Async Data page in "The asyncData Method" section, it says:
"This method receives the context as the first argument"

I think that is a mistake.

manniL

manniL posted a new feature request

docs • 11 days ago

idea Run on random free port

What problem does this feature solve?

Document https://twitter.com/TheAlexLichter/status/1050862540035633152

manniL

manniL posted a new feature request

docs • 12 days ago

idea Extract CSS in a single file

What problem does this feature solve?

Basically document https://github.com/nuxt/nuxt.js/issues/3166#issuecomment-409004911 properly as it was possible before with extractCSS: { allChunks: true } before.

Esslamb

Esslamb implemented the feature request #c120

docs • 12 days ago

idea vuex: this is undefined in arrow function
manniL

manniL posted a new feature request

docs • 12 days ago

idea Best way to insert babel-polyfill

What problem does this feature solve?

There are several ways to do it but we should make it clear in the docs.

  1. Use head/vue-meta to include the script your a CDN
    or
  2. Use a plugin and import it there
manniL

manniL posted a new feature request

docs • 13 days ago

idea Improve `generate.dir` documentation

What problem does this feature solve?

Improve generate.dir documentation (that it is the buildDir for SPA/generate)

Related: https://github.com/nuxt/nuxt.js/issues/3217#issuecomment-381141531

manniL

manniL posted a new question

docs • 13 days ago

Build directory for SPA/generate mode

Improve generate.dir documentation

Related: https://github.com/nuxt/nuxt.js/issues/3217#issuecomment-381141531

manniL

manniL posted a new feature request

docs • 13 days ago

idea vuex: correctly accessing module values in mapState, mapGetters,...

What problem does this feature solve?

Document how to correctly access store module values (like the state) with helpers like mapState.

Related: https://github.com/nuxt/nuxt.js/issues/3790

manniL

manniL posted a new feature request

docs • 13 days ago

idea vuex: this is undefined in arrow function

What problem does this feature solve?

A short hint on https://nuxtjs.org/guide/vuex-store/ that this isn't available if you use arrow functions in file-split store modules would be nice.

Related: https://github.com/nuxt/nuxt.js/issues/4047

manniL

manniL posted a new feature request

docs • 13 days ago

idea Handling of non-SSR-ready components

What problem does this feature solve?

We should add a section about components that are not written in a universal manner (eg. require window/document in created lifecycle method)

Related: https://github.com/nuxt/nuxt.js/issues/3192
https://blog.lichter.io/posts/the-guide-to-write-universal-ssr-ready-vue-compon

manniL

manniL posted a new feature request

docs • 13 days ago

idea Improve asyncData docs

What problem does this feature solve?

The asyncData docs aren't very concise at the moment. An improvement would be great!

  • Called once on server-side, then on client-side (SPA-style)
  • Which arguments are available (and when)
  • What is the difference to fetch
  • Best practices

Ref: https://github.com/nuxt/nuxt.js/issues/2763