This repository was formerly the home of the Deno manual, running at deno.land/manual. The instructions below describe how to run the doc site and preview changes.
New contributions should be made to docs.deno.com
Deprecated - find these resources on docs.deno.com instead
Home Page: https://github.com/denoland/deno-docs
License: MIT License
This repository was formerly the home of the Deno manual, running at deno.land/manual. The instructions below describe how to run the doc site and preview changes.
New contributions should be made to docs.deno.com
"Embedding Deno" chapter is very lax, it should be updated to mention deno_core
and deno_runtime
crates.
Would be great to link to some existing projects that use those crates, eg.
https://github.com/lucacasonato/wgpu_cts_runner
In fetch_data example:
/**
* Output: HTML Data
*/
const textResponse = fetch("https://deno.land/");
const textData = await textResponse.text();
console.log(textData);
Throws error:
> deno run --allow-net test.ts
error: TS2339 [ERROR]: Property 'text' does not exist on type 'Promise<Response>'.
const textData = await textResponse.text();
~~~~
I think the await should be moved? this works:
const textResponse = await fetch("https://deno.land/");
const textData = textResponse.text();
console.log(textData);
Deno Doc 1.13.0 chap 3.5 Websocket example ...
const { webSocket, response } = Deno.upgradeWebSocket(req);
gives error: Property 'webSocket' does not exist on type 'WebSocketUpgrade'.deno-ts(2339)
If I change this to ...
const { socket, response } = Deno.upgradeWebSocket(req);
it works okay.
lib.deno.http_unstable.d.ts
shows
declare namespace Deno {
export interface WebSocketUpgrade {
response: Response;
socket: WebSocket;
}
}
Also, WebSocket.onerror returns (Event | ErrorEvent) so
console.log("socket errored:", e.message);
// Error: Property 'message' does not exist on type 'Event'.deno-ts(2339)
// Changed to
console.log("socket errored:", e.type); // clears the error
Deno not only new js/ts runtime, it is good env for learning js/ts, for this raison I hope we have more example in deno manual or link for good example and use case for worker
There's not a single mention of test steps in https://deno.land/[email protected]/testing
CC @dsherret
Since this is a copy wording change I don't know what is desired here. However, the guidelines said that the PR needs an issue.
Now that the manual is moved out of the main repo, it is a great time to improve the manual website. Here are the primary design constraints:
Code coverage help is as follows:
--coverage=<coverage>
UNSTABLE: Collect coverage profile data
No explanation is given on the parameter value (e.g. <coverage>
), nor is this explained in the manual https://deno.land/[email protected]/testing#test-coverage.
It's not clear at all what value should be given.
The Deno Manual is not working for v1.13.0, it is returning 404 messages. Found this out after clicking a link to the manual in the 1.13.0 release blog post (The previous version 1.12.2 does still work)
Howdy ๐ I was reading up on Deno, as it's something that we're looking to add to our toolchain, and I happened across a few issues talking about naming formats for the registry, and one that referenced the style guide. Given that many (most?) Deno users are Node converts or current users, I found the assertion that snake_cased filenames were considered best practice very curious (https://deno.land/manual/contributing/style_guide#use-underscores-not-dashes-in-filenames). It's something we see in other non-JS language quite often, but it was the first time I'd seen that in something node-adjacent that wasn't authored by python devs.
So I figured there must be a reason, and being open source, some kind of reference, decision making history, or discussion history as to why the decision was made. Being able to tell my team that it's not something that a lone developer decided for arbitrary or personal preferences is pretty important for buy-in. Unfortunately the history for the file in this repo doesn't contain any breadcrumbs that allow for tracing the decision making process for that bit. I thought that was unfortunate.
Can anyone point me in the right direction?
The following parts of the manual aren't as good as they could be for users more familiar with Windows:
/etc/passwd
cat
, which is not available on the command line in windows and code does not work in powershell. Maybe this one is not a big deal to change./usr
and /etc
directory. Tries to access /etc/passwd
https://discord.com/channels/684898665143206084/684898665151594506/870313956982554645
What is the license for this repository, please?
Thank you.
The ## Using the debugger
section in /vscode_deno.md
is empty right now.
Should demo the same thing as is described in getting_started/debugging_your_code.md
, just with VSCode instead of Chrome Dev Tools.
Deno not only new js/ts runtime, it is good env for learning js/ts, for this raison I hope we have more example in deno manual or link for good example and use case for worker
Benchmarking is mostly documented in the README of std/testing
but it would be good to have a manual page on this
I'm willing to PR this, just opening for tracking purposes
I've run into numerous articles informing about the new fast and native HTTP server via the runtime Deno.{listen,serveHttp}
. However, most examples that are available use the higher-level listenAndServe
pulled from std. I would love to know more about differences between these two layers, i.e. what exactly is listenAndServe
doing for me (and for what price/overhead) when compared to the pure-runtime approach (which honestly is not that awfully verbose).
deno_std
WebAssembly.instantiateStreaming
and WebAssembly.compileStreaming
Mentioned in the recent 1.12 blog post: https://deno.com/blog/v1.12#streaming-instantiation-and-async-compilation-support-for-webassembly
Took me a few hours to figure out that the formatter outputs to stderr while I was trying to use command substitution with the output of the formatter, so can a simple sentence be added to the formatter docs for this output behavior?
With denoland/deno#11776 documentation needs to be updated regarding
usage of configuration file.
With denoland/deno#11421 landed, we can now use canary
channel to type check examples in the manual.
Since manual uses $STD_VERSION
tags, we'll need to add an import map file, that will map to latest version of standard library.
This functionality should be added as part of CI script.
CC @caspervonb
Consider adding:
# Install rustup
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
# Install clippy and rustfmt
rustup component add clippy
rustup component add rustfmt
to the contributing docs for deno. These are required to run various formatting tests locally.
Some questions come up on the community Discord on a regular basis, that we should probably add examples for in the manual:
fetch
to a file on disk?Deno.serveHttp
?Once denoland/deno#12024 lands Deno.upgradeWebSocket
will be stable and documentation should be updated accordingly.
Fetch API
The docs don't seem to be updated yet.
It's missing an await
. I've noticed that the main branch is having the fix, but it's not updated on the site.
Once denoland/deno#12293 lands we should add documentation on how to use --compat
flag and what is expected of it.
Blog posts announcing release have a lot of useful information that somehow creeped into being a "de facto" documentation for different features we've added this year.
We should go posts and convert relevant paragraphs into pages in the manual.
Below is the list of all blog posts from this year with proposed paragraphs that could be turned into manual pages:
serde_v8
(add to "Architecture" page)--allow-env
and --allow-run
It points to https://github.com/denoland/deno/docs
Some info and examples can be taken from https://deno.com/blog/v1.13#experimental-ffi-replaces-native-plugin-system
Also note about buffer support (denoland/deno#12335) and non-blocking calls (denoland/deno#12274)
The old section 2.6 on WebAssembly was moved to its own chapter.
However. the "Getting Started" page of the manual still has a link to "Using WebAssembly"...
...and the link leads to a 404 message.
https://deno.land/[email protected]/contributing/architecture#schematic-diagram
libdeno
is replaced with rusty_v8
. This needs to be reflected in the diagram.
The "Tools" section is quite outdated and missing a lot of crucial info, examples:
Taking a look at https://deno.land/[email protected]/getting_started/permissions#permissions-list there are no docs for the --allow-ffi new feature. Also --allow-plugin is there and should have been deprecated.
Thank you!
Should be added to https://deno.land/manual/runtime/http_server_apis
Once denoland/deno#11910 lands we need to update linking_to_external_code/private.md
to reflect that.
Should add a section about setting up for Nova editor.
In the following section in the TypeScript guide explaining how to apply d.ts
file that's you have already.
But person who are familiar Node.js's npm package like me, execute command like npm install -D @types/react
and then get type definition file from DefinitelyTyped.
As a one of React/Node.js developer, current manual seems like unclear to get type definition file of external modules.
I think it's better if the manual is covering that concern clearly.
Thank you. ๐ค
Based on examples from denoland/deno_std#1334
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.